about summary refs log tree commit diff stats
path: root/verbly/token.h
diff options
context:
space:
mode:
Diffstat (limited to 'verbly/token.h')
-rw-r--r--verbly/token.h21
1 files changed, 6 insertions, 15 deletions
diff --git a/verbly/token.h b/verbly/token.h index bbe7c2d..2848fd0 100644 --- a/verbly/token.h +++ b/verbly/token.h
@@ -24,7 +24,8 @@ namespace verbly {
24 enum class fillin_type { 24 enum class fillin_type {
25 noun_phrase, 25 noun_phrase,
26 participle_phrase, 26 participle_phrase,
27 adjective 27 adjective,
28 adverb
28 }; 29 };
29 30
30 class token { 31 class token {
@@ -128,14 +129,14 @@ namespace verbly {
128 return it != other.it; 129 return it != other.it;
129 } 130 }
130 131
131 token* operator*() 132 token& operator*()
132 { 133 {
133 return *it->get(); 134 return **it;
134 } 135 }
135 136
136 token* operator->() 137 token& operator->()
137 { 138 {
138 return *it->get(); 139 return **it;
139 } 140 }
140 };*/ 141 };*/
141 142
@@ -189,16 +190,6 @@ namespace verbly {
189 return std::end(utterance); 190 return std::end(utterance);
190 } 191 }
191 192
192 const iterator begin() const
193 {
194 return std::begin(utterance);
195 }
196
197 const iterator end() const
198 {
199 return std::end(utterance);
200 }
201
202 void erase(iterator it) 193 void erase(iterator it)
203 { 194 {
204 utterance.erase(it); 195 utterance.erase(it);