Fix travis-ci compile error in token extractor
This commit is contained in:
parent
42214ba0eb
commit
d7eca30e58
2 changed files with 3 additions and 3 deletions
|
|
@ -51,7 +51,7 @@ namespace tree_sitter {
|
|||
}
|
||||
|
||||
public:
|
||||
vector<pair<string, const rules::rule_ptr>> aux_rules;
|
||||
vector<pair<string, rules::rule_ptr>> aux_rules;
|
||||
};
|
||||
|
||||
PreparedGrammar expand_repeats(const PreparedGrammar &grammar) {
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ namespace tree_sitter {
|
|||
};
|
||||
|
||||
class TokenExtractor : public rules::RuleFn<rule_ptr> {
|
||||
string add_token(const rule_ptr &rule) {
|
||||
string add_token(rule_ptr rule) {
|
||||
for (auto pair : tokens)
|
||||
if (*pair.second == *rule)
|
||||
return pair.first;
|
||||
|
|
@ -67,7 +67,7 @@ namespace tree_sitter {
|
|||
}
|
||||
|
||||
public:
|
||||
vector<pair<string, const rules::rule_ptr>> tokens;
|
||||
vector<pair<string, rules::rule_ptr>> tokens;
|
||||
};
|
||||
|
||||
pair<PreparedGrammar, PreparedGrammar> extract_tokens(const PreparedGrammar &input_grammar) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue