Home
last modified time | relevance | path

Searched refs:lhs_set (Results 1 – 6 of 6) sorted by relevance

/external/libtextclassifier/native/utils/grammar/utils/
Dir.cc60 bool IsSameLhsSet(const Ir::LhsSet& lhs_set, in IsSameLhsSet() argument
63 if (lhs_set.size() != candidate.lhs.size()) { in IsSameLhsSet()
67 for (int i = 0; i < lhs_set.size(); i++) { in IsSameLhsSet()
69 if (!IsSameLhsEntry(lhs_set[i], candidate.lhs[i], candidates)) { in IsSameLhsSet()
77 Ir::LhsSet SortedLhsSet(const Ir::LhsSet& lhs_set) { in SortedLhsSet() argument
78 Ir::LhsSet sorted_lhs = lhs_set; in SortedLhsSet()
86 return lhs_set; in SortedLhsSet()
91 int AddLhsSet(const Ir::LhsSet& lhs_set, RulesSetT* rules_set) { in AddLhsSet() argument
92 Ir::LhsSet sorted_lhs = SortedLhsSet(lhs_set); in AddLhsSet()
94 const int output_size = rules_set->lhs_set.size(); in AddLhsSet()
[all …]
Dir_test.cc237 EXPECT_THAT(rules.lhs_set, SizeIs(1)); in TEST()
238 EXPECT_THAT(rules.lhs_set.front()->lhs, ElementsAre(test)); in TEST()
Dir.h219 Nonterm AddToSet(const Lhs& lhs, LhsSet* lhs_set);
/external/libtextclassifier/native/utils/grammar/parsing/
Dmatcher.cc171 return rules_set->lhs_set()->Get( in FindTerminalMatches()
186 return rules_set->lhs_set()->Get(entry->value()); in FindUnaryRulesMatches()
214 return rules_set->lhs_set()->Get(rule->lhs_set_index()); in FindBinaryRulesMatches()
271 if (const RulesSet_::LhsSet* lhs_set = in AddTerminal() local
283 lhs_set); in AddTerminal()
287 if (const RulesSet_::LhsSet* lhs_set = FindTerminalMatches( in AddTerminal() local
299 lhs_set); in AddTerminal()
322 const RulesSet_::LhsSet* lhs_set) { in ExecuteLhsSet() argument
323 TC3_CHECK(lhs_set); in ExecuteLhsSet()
326 for (const int32 lhs_entry : *lhs_set->lhs()) { in ExecuteLhsSet()
[all …]
Dmatcher.h104 const RulesSet_::LhsSet* lhs_set);
/external/libtextclassifier/native/utils/grammar/
Drules.fbs31 // This is an offset into the (deduplicated) global `lhs_set` vector.
57 // This is an offset into the (deduplicated) global `lhs_set` vector.
78 // (deduplicated) global `lhs_set` vector.
83 // (deduplicated) global `lhs_set` vector.
187 lhs_set:[RulesSet_.LhsSet];