diff options
| author | Jubilee Young <workingjubilee@gmail.com> | 2024-05-05 15:41:00 -0700 |
|---|---|---|
| committer | Jubilee Young <workingjubilee@gmail.com> | 2024-05-07 19:10:29 -0700 |
| commit | 5e67a3783c89ebb1f611e0351c9a36a579e49cec (patch) | |
| tree | 0d34f2a75fda1e7e59e40e54e1dc9b84e12bf425 /compiler/rustc_parse/src/lib.rs | |
| parent | c70290da0a27a4873823c0381ac698c6e7ed8b65 (diff) | |
| download | rust-5e67a3783c89ebb1f611e0351c9a36a579e49cec.tar.gz rust-5e67a3783c89ebb1f611e0351c9a36a579e49cec.zip | |
compiler: add `Parser::debug_lookahead`
I tried debugging a parser-related issue but found it annoying to not be able to easily peek into the Parser's token stream. Add a convenience fn that offers an opinionated view into the parser, but one that is useful for answering basic questions about parser state.
Diffstat (limited to 'compiler/rustc_parse/src/lib.rs')
| -rw-r--r-- | compiler/rustc_parse/src/lib.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/rustc_parse/src/lib.rs b/compiler/rustc_parse/src/lib.rs index a46372d368f..0f973dfcd79 100644 --- a/compiler/rustc_parse/src/lib.rs +++ b/compiler/rustc_parse/src/lib.rs @@ -5,6 +5,7 @@ #![allow(rustc::untranslatable_diagnostic)] #![feature(array_windows)] #![feature(box_patterns)] +#![feature(debug_closure_helpers)] #![feature(if_let_guard)] #![feature(iter_intersperse)] #![feature(let_chains)] |
