rust/tests/ui/attributes/unix_sigpipe/unix_sigpipe-ident-list.rs
Martin Nordholts 98553ce27e tests: Add ui/attributes/unix_sigpipe/unix_sigpipe-str-list.rs
Which is a variant of [`unix_sigpipe-list.rs`][1] but where a string is
used instead of an identifier. This makes it more similar to the proper
form `#[unix_sigpipe = "sig_dfl"]` and thus more likely to be written by
users by mistake. Also rename the first test to be more in line with the
terminology of [The Reference][2].

[1]: https://github.com/rust-lang/rust/blob/master/tests/ui/attributes/unix_sigpipe/unix_sigpipe-list.rs
[2]: https://doc.rust-lang.org/reference/attributes.html#meta-item-attribute-syntax
2024-03-12 06:04:41 +01:00

5 lines
117 B
Rust

#![feature(unix_sigpipe)]
#[unix_sigpipe(sig_dfl)] //~ error: malformed `unix_sigpipe` attribute input
fn main() {}