We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
#![warn(let_underscore_drop)]
1 parent d355ec9 commit 76c90c3Copy full SHA for 76c90c3
src/test/ui/lint/let_underscore/let_underscore_drop.rs
@@ -1,5 +1,5 @@
1
// check-pass
2
-// compile-flags: -W let_underscore_drop
+#![warn(let_underscore_drop)]
3
4
struct NontrivialDrop;
5
src/test/ui/lint/let_underscore/let_underscore_drop.stderr
@@ -4,7 +4,11 @@ warning: non-binding let on a type that implements `Drop`
LL | let _ = NontrivialDrop;
| ^^^^^^^^^^^^^^^^^^^^^^^
6
|
7
- = note: requested on the command line with `-W let-underscore-drop`
+note: the lint level is defined here
8
+ --> $DIR/let_underscore_drop.rs:2:9
9
+ |
10
+LL | #![warn(let_underscore_drop)]
11
+ | ^^^^^^^^^^^^^^^^^^^
12
help: consider binding to an unused variable to avoid immediately dropping the value
13
14
LL | let _unused = NontrivialDrop;
0 commit comments