Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Hit some issues when attempting to run verusfmt on https://github.com/secure-foundations/human-eval-verus/blob/main/tasks/human_eval_001.rs ; specifically, our minimal parser would consider the parenthesis in `'('` to be syntactically-relevant, rather than ignore it, thereby causing a: ``` thread 'main' panicked at src/rustfmt.rs:51:10: Minimal parsing should never fail. If it did, please report this as an error.: Error { variant: ParsingError { positives: [COMMENT, tt], negatives: [] }, location: Pos(5984), line_col: Pos((155, 9)), path: None, line: " } else if c == ')' {", continued_line: None } note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace ``` This PR fixes the issues. Automatically-minimized example that triggers the issue before this PR: ```rs verus! { fn a() ensures { { if '(' { if 0 { } } } } } // verus! ```
- Loading branch information