aea60b0cc7
The `sig_dfl` variant of the attribute is the most likely variant to be stabilized first, and thus to become the "most allowed" variant of the attribute. Because of this, it is the most appropriate variant to use in syntax tests, because even if the most allowed variant is used, the compiler shall still emit errors if it e.g. is used in the wrong places.
18 lines
433 B
Plaintext
18 lines
433 B
Plaintext
error: `unix_sigpipe` attribute cannot be used at crate level
|
|
--> $DIR/unix_sigpipe-crate.rs:2:1
|
|
|
|
|
LL | #![unix_sigpipe = "sig_dfl"]
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
LL |
|
|
LL | fn main() {}
|
|
| ---- the inner attribute doesn't annotate this function
|
|
|
|
|
help: perhaps you meant to use an outer attribute
|
|
|
|
|
LL - #![unix_sigpipe = "sig_dfl"]
|
|
LL + #[unix_sigpipe = "sig_dfl"]
|
|
|
|
|
|
|
error: aborting due to 1 previous error
|
|
|