]> git.lizzy.rs Git - rust.git/blob - src/test/ui/parser/issue-70583-block-is-empty-2.rs
Writing tests
[rust.git] / src / test / ui / parser / issue-70583-block-is-empty-2.rs
1 pub enum ErrorHandled {
2     Reported,
3     TooGeneric,
4 }
5
6 impl ErrorHandled {
7     pub fn assert_reported(self) {
8         match self {
9             ErrorHandled::Reported => {}} 
10                                      //^~ ERROR this block is empty, you might have not mean to close it
11             ErrorHandled::TooGeneric => panic!(),
12         }
13     }
14 } //~ ERROR unexpected closing delimiter: `}`