File tree 2 files changed +4
-14
lines changed
2 files changed +4
-14
lines changed Original file line number Diff line number Diff line change @@ -31,8 +31,6 @@ class SuffixTree
31
31
template <class Iterator >
32
32
Iterator inc_search (Iterator sub)
33
33
{
34
- typedef typename Iterator::value_type T; // extract real type
35
-
36
34
Iterator result = sub;
37
35
Node* node = &root;
38
36
Edge* edge = NULL ;
@@ -73,13 +71,7 @@ class SuffixTree
73
71
return result;
74
72
}
75
73
76
- int print_tree (void );
77
- private:
78
- string test_str;
79
-
80
74
struct Node ;
81
- typedef struct Node Node;
82
-
83
75
struct Edge {
84
76
// the begin and end pos of this edge, note that INT_MAX stands for #(the changing end pos of this entire string)
85
77
unsigned int begin, end;
@@ -146,7 +138,6 @@ class SuffixTree
146
138
147
139
bool is_none (void ) { return begin == 0 && end == 0 ; }
148
140
};
149
- typedef struct Edge Edge;
150
141
151
142
struct Node {
152
143
string& test_node_str;
@@ -224,10 +215,9 @@ class SuffixTree
224
215
return os;
225
216
}
226
217
};
227
- // typedef struct Node Node;
228
-
229
- friend struct Node ;
230
-
218
+ int print_tree (void );
219
+ private:
220
+ string test_str;
231
221
class ActivePoint {
232
222
public:
233
223
Node* active_node;
Original file line number Diff line number Diff line change @@ -104,7 +104,7 @@ int SuffixTree::construct(void)
104
104
return 0 ;
105
105
}
106
106
107
- SuffixTree::Node* SuffixTree::seperate_edge (Node * node, Edge* a_edge)
107
+ SuffixTree::Node* SuffixTree::separate_edge (Node * node, Edge* a_edge)
108
108
{
109
109
cout << " separate the old edge here: " << (*a_edge) << endl;
110
110
int new_begin = a_edge->begin + get_active_length ();
You can’t perform that action at this time.
0 commit comments