]> git.lizzy.rs Git - rust.git/blob - src/test/ui/parser/parser-recovery-1.rs
Rollup merge of #92024 - pcwalton:per-codegen-unit-names, r=davidtwco
[rust.git] / src / test / ui / parser / parser-recovery-1.rs
1 // Test that we can recover from missing braces in the parser.
2
3 trait Foo {
4     fn bar() {
5         let x = foo();
6         //~^ ERROR cannot find function `foo` in this scope
7 }
8
9 fn main() {
10     let x = y.;
11     //~^ ERROR unexpected token
12     //~| ERROR cannot find value `y` in this scope
13 } //~ ERROR this file contains an unclosed delimiter