You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
= note: one exception to the rule are anon-const (`const _: () = { ... }`) at top-level module and anon-const at the same nesting as the trait or type
10
10
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
11
11
= note: the macro `non_local_macro::non_local_impl` may come from an old version of the `non_local_macro` crate, try updating your dependency with `cargo update -p non_local_macro`
12
-
= note: `#[warn(non_local_definitions)]` on by default
12
+
note: the lint level is defined here
13
+
--> $DIR/cargo-update.rs:13:9
14
+
|
15
+
LL | #![warn(non_local_definitions)]
16
+
| ^^^^^^^^^^^^^^^^^^^^^
13
17
= note: this warning originates in the macro `non_local_macro::non_local_impl` (in Nightly builds, run with -Z macro-backtrace for more info)
Copy file name to clipboardExpand all lines: tests/ui/lint/non-local-defs/consts.stderr
+13-9
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
warning: non-local `impl` definition, they should be avoided as they go against expectation
2
-
--> $DIR/consts.rs:13:5
2
+
--> $DIR/consts.rs:15:5
3
3
|
4
4
LL | const Z: () = {
5
5
| - help: use a const-anon item to suppress this lint: `_`
@@ -11,10 +11,14 @@ LL | impl Uto for &Test {}
11
11
= note: an `impl` definition is non-local if it is nested inside an item and may impact type checking outside of that item. This can be the case if neither the trait or the self type are at the same nesting level as the `impl`
12
12
= note: one exception to the rule are anon-const (`const _: () = { ... }`) at top-level module and anon-const at the same nesting as the trait or type
13
13
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
14
-
= note: `#[warn(non_local_definitions)]` on by default
14
+
note: the lint level is defined here
15
+
--> $DIR/consts.rs:5:9
16
+
|
17
+
LL | #![warn(non_local_definitions)]
18
+
| ^^^^^^^^^^^^^^^^^^^^^
15
19
16
20
warning: non-local `impl` definition, they should be avoided as they go against expectation
17
-
--> $DIR/consts.rs:24:5
21
+
--> $DIR/consts.rs:26:5
18
22
|
19
23
LL | impl Uto2 for Test {}
20
24
| ^^^^^^^^^^^^^^^^^^^^^
@@ -25,7 +29,7 @@ LL | impl Uto2 for Test {}
25
29
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
26
30
27
31
warning: non-local `impl` definition, they should be avoided as they go against expectation
28
-
--> $DIR/consts.rs:32:5
32
+
--> $DIR/consts.rs:34:5
29
33
|
30
34
LL | impl Uto3 for Test {}
31
35
| ^^^^^^^^^^^^^^^^^^^^^
@@ -36,7 +40,7 @@ LL | impl Uto3 for Test {}
36
40
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
37
41
38
42
warning: non-local `impl` definition, they should be avoided as they go against expectation
39
-
--> $DIR/consts.rs:43:5
43
+
--> $DIR/consts.rs:45:5
40
44
|
41
45
LL | / impl Test {
42
46
LL | |
@@ -50,7 +54,7 @@ LL | | }
50
54
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
51
55
52
56
warning: non-local `impl` definition, they should be avoided as they go against expectation
53
-
--> $DIR/consts.rs:50:9
57
+
--> $DIR/consts.rs:52:9
54
58
|
55
59
LL | / impl Test {
56
60
LL | |
@@ -64,7 +68,7 @@ LL | | }
64
68
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
65
69
66
70
warning: non-local `impl` definition, they should be avoided as they go against expectation
67
-
--> $DIR/consts.rs:59:9
71
+
--> $DIR/consts.rs:61:9
68
72
|
69
73
LL | / impl Test {
70
74
LL | |
@@ -78,7 +82,7 @@ LL | | }
78
82
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
79
83
80
84
warning: non-local `impl` definition, they should be avoided as they go against expectation
81
-
--> $DIR/consts.rs:72:9
85
+
--> $DIR/consts.rs:74:9
82
86
|
83
87
LL | impl Uto9 for Test {}
84
88
| ^^^^^^^^^^^^^^^^^^^^^
@@ -89,7 +93,7 @@ LL | impl Uto9 for Test {}
89
93
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
90
94
91
95
warning: non-local `impl` definition, they should be avoided as they go against expectation
Copy file name to clipboardExpand all lines: tests/ui/lint/non-local-defs/exhaustive-trait.stderr
+11-7
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
warning: non-local `impl` definition, they should be avoided as they go against expectation
2
-
--> $DIR/exhaustive-trait.rs:7:5
2
+
--> $DIR/exhaustive-trait.rs:9:5
3
3
|
4
4
LL | / impl PartialEq<()> for Dog {
5
5
LL | |
@@ -13,10 +13,14 @@ LL | | }
13
13
= note: an `impl` definition is non-local if it is nested inside an item and may impact type checking outside of that item. This can be the case if neither the trait or the self type are at the same nesting level as the `impl`
14
14
= note: one exception to the rule are anon-const (`const _: () = { ... }`) at top-level module and anon-const at the same nesting as the trait or type
15
15
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
16
-
= note: `#[warn(non_local_definitions)]` on by default
16
+
note: the lint level is defined here
17
+
--> $DIR/exhaustive-trait.rs:4:9
18
+
|
19
+
LL | #![warn(non_local_definitions)]
20
+
| ^^^^^^^^^^^^^^^^^^^^^
17
21
18
22
warning: non-local `impl` definition, they should be avoided as they go against expectation
19
-
--> $DIR/exhaustive-trait.rs:14:5
23
+
--> $DIR/exhaustive-trait.rs:16:5
20
24
|
21
25
LL | / impl PartialEq<()> for &Dog {
22
26
LL | |
@@ -32,7 +36,7 @@ LL | | }
32
36
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
33
37
34
38
warning: non-local `impl` definition, they should be avoided as they go against expectation
35
-
--> $DIR/exhaustive-trait.rs:21:5
39
+
--> $DIR/exhaustive-trait.rs:23:5
36
40
|
37
41
LL | / impl PartialEq<Dog> for () {
38
42
LL | |
@@ -48,7 +52,7 @@ LL | | }
48
52
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
49
53
50
54
warning: non-local `impl` definition, they should be avoided as they go against expectation
51
-
--> $DIR/exhaustive-trait.rs:28:5
55
+
--> $DIR/exhaustive-trait.rs:30:5
52
56
|
53
57
LL | / impl PartialEq<&Dog> for () {
54
58
LL | |
@@ -64,7 +68,7 @@ LL | | }
64
68
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
65
69
66
70
warning: non-local `impl` definition, they should be avoided as they go against expectation
67
-
--> $DIR/exhaustive-trait.rs:35:5
71
+
--> $DIR/exhaustive-trait.rs:37:5
68
72
|
69
73
LL | / impl PartialEq<Dog> for &Dog {
70
74
LL | |
@@ -80,7 +84,7 @@ LL | | }
80
84
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
81
85
82
86
warning: non-local `impl` definition, they should be avoided as they go against expectation
Copy file name to clipboardExpand all lines: tests/ui/lint/non-local-defs/exhaustive.stderr
+25-21
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
warning: non-local `impl` definition, they should be avoided as they go against expectation
2
-
--> $DIR/exhaustive.rs:10:5
2
+
--> $DIR/exhaustive.rs:12:5
3
3
|
4
4
LL | / impl Test {
5
5
LL | |
@@ -11,10 +11,14 @@ LL | | }
11
11
= note: an `impl` definition is non-local if it is nested inside an item and may impact type checking outside of that item. This can be the case if neither the trait or the self type are at the same nesting level as the `impl`
12
12
= note: one exception to the rule are anon-const (`const _: () = { ... }`) at top-level module and anon-const at the same nesting as the trait or type
13
13
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
14
-
= note: `#[warn(non_local_definitions)]` on by default
14
+
note: the lint level is defined here
15
+
--> $DIR/exhaustive.rs:4:9
16
+
|
17
+
LL | #![warn(non_local_definitions)]
18
+
| ^^^^^^^^^^^^^^^^^^^^^
15
19
16
20
warning: non-local `impl` definition, they should be avoided as they go against expectation
17
-
--> $DIR/exhaustive.rs:15:5
21
+
--> $DIR/exhaustive.rs:17:5
18
22
|
19
23
LL | / impl Display for Test {
20
24
LL | |
@@ -30,7 +34,7 @@ LL | | }
30
34
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
31
35
32
36
warning: non-local `impl` definition, they should be avoided as they go against expectation
33
-
--> $DIR/exhaustive.rs:22:5
37
+
--> $DIR/exhaustive.rs:24:5
34
38
|
35
39
LL | impl dyn Trait {}
36
40
| ^^^^^^^^^^^^^^^^^
@@ -41,7 +45,7 @@ LL | impl dyn Trait {}
41
45
= note: this lint may become deny-by-default in the edition 2024 and higher, see the tracking issue <https://github.com/rust-lang/rust/issues/120363>
42
46
43
47
warning: non-local `impl` definition, they should be avoided as they go against expectation
0 commit comments