This commit completely removes usage of the `panictry!` macro from outside libsyntax. The macro causes parse errors to be fatal, so using it in libsyntax_ext caused parse failures *within* a syntax extension to be fatal, which is probably not intended. Furthermore, this commit adds spans to diagnostics emitted by empty extensions if they were missing, à la #56491.
5 lines
191 B
Rust
5 lines
191 B
Rust
fn main() {
|
|
cfg!(); //~ ERROR macro requires a cfg-pattern
|
|
cfg!(123); //~ ERROR expected identifier
|
|
cfg!(foo = 123); //~ ERROR literal in `cfg` predicate value must be a string
|
|
}
|