Make more things immutable

This commit is contained in:
Max Brunsfeld 2013-11-13 20:22:06 -08:00
parent f7063ba1d8
commit 8a0a442a24
12 changed files with 40 additions and 60 deletions

View file

@ -11,7 +11,7 @@ namespace tree_sitter {
consumed_sym_count(consumed_sym_count) {};
Item Item::at_beginning_of_rule(const std::string &rule_name, Grammar &grammar) {
return Item(rule_name, grammar.rules[rule_name], 0);
return Item(rule_name, grammar.rule(rule_name), 0);
}
TransitionMap<Item> Item::transitions() const {