diff options
author | Aleksey Kladov <[email protected]> | 2018-01-20 21:31:29 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2018-01-20 21:31:29 +0000 |
commit | efd538d793c714a3167a216f032be7b7d34c1d57 (patch) | |
tree | 4b6a58c1922de2a7aba018375f365752baa5cd80 /src/parser/event_parser/grammar/mod.rs | |
parent | 0b5d39f2a204e5ec6cd6205440e4cdc763162814 (diff) |
Remove high-order bits from attributes
Diffstat (limited to 'src/parser/event_parser/grammar/mod.rs')
-rw-r--r-- | src/parser/event_parser/grammar/mod.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/parser/event_parser/grammar/mod.rs b/src/parser/event_parser/grammar/mod.rs index d3b63c4c1..32e4db698 100644 --- a/src/parser/event_parser/grammar/mod.rs +++ b/src/parser/event_parser/grammar/mod.rs | |||
@@ -1,4 +1,4 @@ | |||
1 | use super::parser::Parser; | 1 | use super::parser::{Parser, TokenSet}; |
2 | use {SyntaxKind}; | 2 | use {SyntaxKind}; |
3 | use tree::EOF; | 3 | use tree::EOF; |
4 | use syntax_kinds::*; | 4 | use syntax_kinds::*; |
@@ -80,8 +80,8 @@ fn comma_list<F: Fn(&mut Parser) -> bool>(p: &mut Parser, end: SyntaxKind, f: F) | |||
80 | 80 | ||
81 | 81 | ||
82 | impl<'p> Parser<'p> { | 82 | impl<'p> Parser<'p> { |
83 | fn at(&self, kind: SyntaxKind) -> bool { | 83 | fn at<L: Lookahead>(&self, l: L) -> bool { |
84 | self.current() == kind | 84 | l.is_ahead(self) |
85 | } | 85 | } |
86 | 86 | ||
87 | pub(crate) fn expect(&mut self, kind: SyntaxKind) -> bool { | 87 | pub(crate) fn expect(&mut self, kind: SyntaxKind) -> bool { |