Skip to content

Commit

Permalink
Fix is_keyword_ahead visibility
Browse files Browse the repository at this point in the history
Co-authored-by: Takayuki Maeda <takoyaki0316@gmail.com>
  • Loading branch information
sjwang05 and TaKO8Ki committed Nov 12, 2023
1 parent f88cf02 commit 274824b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion compiler/rustc_parse/src/parser/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1115,7 +1115,7 @@ impl<'a> Parser<'a> {
}

/// Returns whether any of the given keywords are `dist` tokens ahead of the current one.
pub fn is_keyword_ahead(&self, dist: usize, kws: &[Symbol]) -> bool {
pub(crate) fn is_keyword_ahead(&self, dist: usize, kws: &[Symbol]) -> bool {
self.look_ahead(dist, |t| kws.iter().any(|&kw| t.is_keyword(kw)))
}

Expand Down

0 comments on commit 274824b

Please sign in to comment.