diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/lint/lint-misplaced-attr.stderr | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/test/ui/lint/lint-misplaced-attr.stderr b/src/test/ui/lint/lint-misplaced-attr.stderr new file mode 100644 index 000000000..abaf4620e --- /dev/null +++ b/src/test/ui/lint/lint-misplaced-attr.stderr @@ -0,0 +1,20 @@ +error: crate-level attribute should be in the root module + --> $DIR/lint-misplaced-attr.rs:7:5 + | +LL | #![crate_type = "bin"] + | ^^^^^^^^^^^^^^^^^^^^^^ + | +note: the lint level is defined here + --> $DIR/lint-misplaced-attr.rs:4:9 + | +LL | #![deny(unused_attributes)] + | ^^^^^^^^^^^^^^^^^ + +error: crate-level attribute should be an inner attribute: add an exclamation mark: `#![foo]` + --> $DIR/lint-misplaced-attr.rs:10:1 + | +LL | #[crate_type = "bin"] fn main() {} + | ^^^^^^^^^^^^^^^^^^^^^ + +error: aborting due to 2 previous errors + |