summary refs log tree commit diff stats
path: root/lib/token.h
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2017-02-19 15:36:03 -0500
committerKelly Rauchenberger <fefferburbia@gmail.com>2017-02-19 15:36:03 -0500
commit8916c6911c23ca7ff7e78a90b30a295c2b9b9c22 (patch)
treee5f22f29edf845960e435a44220bf613d2baa24f /lib/token.h
parent49d6f0387f7b7cc3c6a51ef8fcdf519da98487f6 (diff)
downloadverbly-8916c6911c23ca7ff7e78a90b30a295c2b9b9c22.tar.gz
verbly-8916c6911c23ca7ff7e78a90b30a295c2b9b9c22.tar.bz2
verbly-8916c6911c23ca7ff7e78a90b30a295c2b9b9c22.zip
Added method to check if a token is empty
Diffstat (limited to 'lib/token.h')
-rw-r--r--lib/token.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/token.h b/lib/token.h index f3188c9..a4072e0 100644 --- a/lib/token.h +++ b/lib/token.h
@@ -50,6 +50,11 @@ namespace verbly {
50 50
51 std::string compile() const; 51 std::string compile() const;
52 52
53 bool isEmpty() const
54 {
55 return ((type_ == type::utterance) && (utterance_.empty()));
56 }
57
53 // Word 58 // Word
54 59
55 token(word arg, inflection category = inflection::base); 60 token(word arg, inflection category = inflection::base);