Optimize parse item equality

This commit is contained in:
Max Brunsfeld 2014-04-28 18:31:03 -07:00
parent 70ba76762c
commit 66c033e411

View file

@ -21,7 +21,7 @@ namespace tree_sitter {
(other.lhs == lhs) &&
(other.consumed_symbol_count == consumed_symbol_count) &&
(other.lookahead_sym == lookahead_sym) &&
(other.rule->operator==(*rule));
(other.rule == rule || other.rule->operator==(*rule));
}
int ParseItem::precedence() const {