Add test for issue-62894
This commit is contained in:
parent
f32447d541
commit
ecb8bf069e
7
src/test/ui/parser/issue-62894.rs
Normal file
7
src/test/ui/parser/issue-62894.rs
Normal file
@ -0,0 +1,7 @@
|
||||
// Regression test for #62894, shouldn't crash.
|
||||
// error-pattern: this file contains an unclosed delimiter
|
||||
// error-pattern: expected one of `(`, `[`, or `{`, found keyword `fn`
|
||||
|
||||
fn f() { assert_eq!(f(), (), assert_eq!(assert_eq!
|
||||
|
||||
fn main() {}
|
47
src/test/ui/parser/issue-62894.stderr
Normal file
47
src/test/ui/parser/issue-62894.stderr
Normal file
@ -0,0 +1,47 @@
|
||||
error: this file contains an unclosed delimiter
|
||||
--> $DIR/issue-62894.rs:7:14
|
||||
|
|
||||
LL | fn f() { assert_eq!(f(), (), assert_eq!(assert_eq!
|
||||
| - - - unclosed delimiter
|
||||
| | |
|
||||
| | unclosed delimiter
|
||||
| unclosed delimiter
|
||||
LL |
|
||||
LL | fn main() {}
|
||||
| ^
|
||||
|
||||
error: this file contains an unclosed delimiter
|
||||
--> $DIR/issue-62894.rs:7:14
|
||||
|
|
||||
LL | fn f() { assert_eq!(f(), (), assert_eq!(assert_eq!
|
||||
| - - - unclosed delimiter
|
||||
| | |
|
||||
| | unclosed delimiter
|
||||
| unclosed delimiter
|
||||
LL |
|
||||
LL | fn main() {}
|
||||
| ^
|
||||
|
||||
error: this file contains an unclosed delimiter
|
||||
--> $DIR/issue-62894.rs:7:14
|
||||
|
|
||||
LL | fn f() { assert_eq!(f(), (), assert_eq!(assert_eq!
|
||||
| - - - unclosed delimiter
|
||||
| | |
|
||||
| | unclosed delimiter
|
||||
| unclosed delimiter
|
||||
LL |
|
||||
LL | fn main() {}
|
||||
| ^
|
||||
|
||||
error: expected one of `(`, `[`, or `{`, found keyword `fn`
|
||||
--> $DIR/issue-62894.rs:7:1
|
||||
|
|
||||
LL | fn f() { assert_eq!(f(), (), assert_eq!(assert_eq!
|
||||
| - expected one of `(`, `[`, or `{`
|
||||
LL |
|
||||
LL | fn main() {}
|
||||
| ^^ unexpected token
|
||||
|
||||
error: aborting due to 4 previous errors
|
||||
|
Loading…
Reference in New Issue
Block a user