From 8916c6911c23ca7ff7e78a90b30a295c2b9b9c22 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Sun, 19 Feb 2017 15:36:03 -0500 Subject: Added method to check if a token is empty --- lib/token.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'lib/token.h') 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 { std::string compile() const; + bool isEmpty() const + { + return ((type_ == type::utterance) && (utterance_.empty())); + } + // Word token(word arg, inflection category = inflection::base); -- cgit 1.4.1