about summary refs log tree commit diff stats
path: root/sentence.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'sentence.cpp')
-rw-r--r--sentence.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/sentence.cpp b/sentence.cpp index 6cfa0c3..ae485c0 100644 --- a/sentence.cpp +++ b/sentence.cpp
@@ -233,7 +233,7 @@ verbly::token sentence::generateStandardNounPhrase(
233 { 233 {
234 utter << "your"; 234 utter << "your";
235 } else if (!plural) { 235 } else if (!plural) {
236 if (sounder.getLemma().getBaseForm().startsWithVowelSound()) 236 if (sounder.getBaseForm().startsWithVowelSound())
237 { 237 {
238 utter << "an"; 238 utter << "an";
239 } else { 239 } else {
@@ -242,12 +242,12 @@ verbly::token sentence::generateStandardNounPhrase(
242 } 242 }
243 } 243 }
244 244
245 if (descript) 245 if (descript.isValid())
246 { 246 {
247 utter << descript; 247 utter << descript;
248 } 248 }
249 249
250 if (plural && noun.getLemma().hasInflection(verbly::inflection::plural)) 250 if (plural && noun.hasInflection(verbly::inflection::plural))
251 { 251 {
252 utter << verbly::token(noun, verbly::inflection::plural); 252 utter << verbly::token(noun, verbly::inflection::plural);
253 } else { 253 } else {
@@ -290,13 +290,13 @@ verbly::token sentence::generateClause(
290 290
291 if (it.hasSynrestr("participle_phrase")) 291 if (it.hasSynrestr("participle_phrase"))
292 { 292 {
293 verbCondition &= (verbly::lemma::forms(verbly::inflection::ing_form)); 293 verbCondition &= (verbly::word::forms(verbly::inflection::ing_form));
294 } else if (it.hasSynrestr("progressive")) 294 } else if (it.hasSynrestr("progressive"))
295 { 295 {
296 verbCondition &= (verbly::lemma::forms(verbly::inflection::s_form)); 296 verbCondition &= (verbly::word::forms(verbly::inflection::s_form));
297 } else if (it.hasSynrestr("past_participle")) 297 } else if (it.hasSynrestr("past_participle"))
298 { 298 {
299 verbCondition &= (verbly::lemma::forms(verbly::inflection::past_participle)); 299 verbCondition &= (verbly::word::forms(verbly::inflection::past_participle));
300 } 300 }
301 301
302 // Because of the tag distribution, it's possible (albeit extremely unlikely) 302 // Because of the tag distribution, it's possible (albeit extremely unlikely)
@@ -459,7 +459,7 @@ verbly::token sentence::generateClause(
459 459
460 case verbly::part_type::verb: 460 case verbly::part_type::verb:
461 { 461 {
462 std::cout << "V: " << verb.getBaseForm() << std::endl; 462 std::cout << "V: " << verb.getBaseForm().getText() << std::endl;
463 463
464 if (it.hasSynrestr("progressive")) 464 if (it.hasSynrestr("progressive"))
465 { 465 {
@@ -609,7 +609,7 @@ void sentence::visit(verbly::token& it) const
609 it = verbly::token( 609 it = verbly::token(
610 database_.words( 610 database_.words(
611 (verbly::notion::partOfSpeech == verbly::part_of_speech::verb) 611 (verbly::notion::partOfSpeech == verbly::part_of_speech::verb)
612 && (verbly::lemma::forms(verbly::inflection::ing_form))).first(), 612 && (verbly::word::forms(verbly::inflection::ing_form))).first(),
613 verbly::inflection::ing_form); 613 verbly::inflection::ing_form);
614 } else { 614 } else {
615 it = generateClause(it); 615 it = generateClause(it);