Skip to content

Commit 873db46

Browse files
committed
Inflection-77 Test results
1 parent e676a21 commit 873db46

File tree

4 files changed

+10
-3
lines changed

4 files changed

+10
-3
lines changed

inflection/src/inflection/grammar/synthesis/FrGrammarSynthesizer_CountLookupFunction.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ ::std::optional<::std::u16string> FrGrammarSynthesizer_CountLookupFunction::dete
6767
int64_t wordGrammemes = 0;
6868
dictionary.getCombinedBinaryType(&wordGrammemes, word);
6969
if ((wordGrammemes & properNounProperty) == properNounProperty) {
70-
return {{}};
70+
return std::u16string{};
7171
}
7272
if (checkInvariantNouns(word, wordGrammemes)) {
7373
return GrammemeConstants::NUMBER_SINGULAR();

inflection/src/inflection/grammar/synthesis/HiGrammarSynthesizer_HiDisplayFunction.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ ::std::optional<::std::u16string> HiGrammarSynthesizer_HiDisplayFunction::inflec
185185

186186
::std::optional<::std::vector<::std::u16string>> HiGrammarSynthesizer_HiDisplayFunction::inflectSignificantWords(const std::vector<::std::u16string> &words, const ::std::map<SemanticFeature, ::std::u16string> &constraints, bool enableInflectionGuess) const {
187187
if (words.empty()) {
188-
return {{}};
188+
return std::vector<std::u16string>{};
189189
}
190190
const auto &dictionary = dictionaryInflector.getDictionary();
191191
int64_t adpositionIndex = -1;

inflection/src/inflection/grammar/synthesis/PtGrammarSynthesizer_PtDisplayFunction.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ ::std::optional<::std::vector<::std::u16string>> PtGrammarSynthesizer_PtDisplayF
195195

196196
::std::optional<::std::vector<::std::u16string>> PtGrammarSynthesizer_PtDisplayFunction::inflectSignificantWords(const std::vector<::std::u16string> &words, const ::std::map<::inflection::dialog::SemanticFeature, ::std::u16string> &constraints, bool enableInflectionGuess) const {
197197
switch (words.size()) {
198-
case 0: return {{}};
198+
case 0: return std::vector<std::u16string>{};
199199
case 1: {
200200
int64_t wordType = 0;
201201
dictionary.getCombinedBinaryType(&wordType, words[0]);

inflection/test/resources/inflection/dialog/inflection/es.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -221,4 +221,11 @@
221221
<test><source definiteness="definite">álgebra añeja</source><result>el álgebra añeja</result></test> <!-- An exception to the gender rule. -->
222222
<test><source definiteness="definite">añeja álgebra</source><result>la añeja álgebra</result></test>
223223
<test><source>área</source><result withDemAdj="esta área"/></test>
224+
225+
<!-- New Tests for stating grammemes ~ bhaskar -->
226+
<test><source definiteness="definite">cometa</source><initial gender="masculine"/><result number="singular" gender="masculine">el cometa</result></test>
227+
<test><source definiteness="definite">cometa</source><initial gender="feminine"/><result number="singular" gender="feminine">la cometa</result></test>
228+
<test><source definiteness="definite">QQQQ</source><initial gender="masculine" number="plural"/><result number="plural" gender="masculine">los QQQQ</result></test>
229+
<test><source definiteness="definite">QQQQ</source><initial gender="feminine" number="plural"/><result number="plural" gender="masculine">las QQQQ</result></test>
230+
224231
</inflectionTest>

0 commit comments

Comments
 (0)