Use ui test syntax that does not interfere with rustfmt

This commit is contained in:
David Tolnay 2024-11-10 23:51:22 -08:00
parent 15fd26e476
commit ad2f20b9f7
No known key found for this signature in database
GPG key ID: F9BA143B95FF6D82
2 changed files with 4 additions and 4 deletions

View file

@ -5,5 +5,5 @@ use thiserror::Error;
pub struct Error; pub struct Error;
fn main() { fn main() {
@//fail __FAIL__;
} }

View file

@ -1,8 +1,8 @@
error: expected expression, found `@` error[E0425]: cannot find value `__FAIL__` in this scope
--> tests/ui/unconditional-recursion.rs:8:5 --> tests/ui/unconditional-recursion.rs:8:5
| |
8 | @//fail 8 | __FAIL__;
| ^ expected expression | ^^^^^^^^ not found in this scope
warning: function cannot return without recursing warning: function cannot return without recursing
--> tests/ui/unconditional-recursion.rs:4:9 --> tests/ui/unconditional-recursion.rs:4:9