Skip to content

Commit 536b4ab

Browse files
committed
Fix future-incompatible lint group test
1 parent 6e23095 commit 536b4ab

File tree

2 files changed

+35
-15
lines changed

2 files changed

+35
-15
lines changed

tests/ui/future-incompatible-lint-group.rs

+4-6
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,14 @@
22
// lints for changes that are not tied to an edition
33
#![deny(future_incompatible)]
44

5+
// Error since this is a `future_incompatible` lint
6+
macro_rules! m { ($i) => {} } //~ ERROR missing fragment specifier
7+
//~| WARN this was previously accepted
8+
59
trait Tr {
610
// Warn only since this is not a `future_incompatible` lint
711
fn f(u8) {} //~ WARN anonymous parameters are deprecated
812
//~| WARN this is accepted in the current edition
913
}
1014

11-
pub mod submodule {
12-
// Error since this is a `future_incompatible` lint
13-
#![doc(test(some_test))]
14-
//~^ ERROR this attribute can only be applied at the crate level
15-
}
16-
1715
fn main() {}
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,20 @@
1+
error: missing fragment specifier
2+
--> $DIR/future-incompatible-lint-group.rs:6:19
3+
|
4+
LL | macro_rules! m { ($i) => {} }
5+
| ^^
6+
|
7+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
8+
= note: for more information, see issue #40107 <https://github.com/rust-lang/rust/issues/40107>
9+
note: the lint level is defined here
10+
--> $DIR/future-incompatible-lint-group.rs:3:9
11+
|
12+
LL | #![deny(future_incompatible)]
13+
| ^^^^^^^^^^^^^^^^^^^
14+
= note: `#[deny(missing_fragment_specifier)]` implied by `#[deny(future_incompatible)]`
15+
116
warning: anonymous parameters are deprecated and will be removed in the next edition
2-
--> $DIR/future-incompatible-lint-group.rs:7:10
17+
--> $DIR/future-incompatible-lint-group.rs:11:10
318
|
419
LL | fn f(u8) {}
520
| ^^ help: try naming the parameter or explicitly ignoring it: `_: u8`
@@ -8,14 +23,21 @@ LL | fn f(u8) {}
823
= note: for more information, see issue #41686 <https://github.com/rust-lang/rust/issues/41686>
924
= note: `#[warn(anonymous_parameters)]` on by default
1025

11-
error: this attribute can only be applied at the crate level
12-
--> $DIR/future-incompatible-lint-group.rs:13:12
26+
error: aborting due to 1 previous error; 1 warning emitted
27+
28+
Future incompatibility report: Future breakage diagnostic:
29+
error: missing fragment specifier
30+
--> $DIR/future-incompatible-lint-group.rs:6:19
1331
|
14-
LL | #![doc(test(some_test))]
15-
| ^^^^^^^^^^^^^^^
32+
LL | macro_rules! m { ($i) => {} }
33+
| ^^
1634
|
17-
= note: read <https://doc.rust-lang.org/nightly/rustdoc/the-doc-attribute.html#at-the-crate-level> for more information
18-
= note: `#[deny(invalid_doc_attributes)]` on by default
19-
20-
error: aborting due to 1 previous error; 1 warning emitted
35+
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
36+
= note: for more information, see issue #40107 <https://github.com/rust-lang/rust/issues/40107>
37+
note: the lint level is defined here
38+
--> $DIR/future-incompatible-lint-group.rs:3:9
39+
|
40+
LL | #![deny(future_incompatible)]
41+
| ^^^^^^^^^^^^^^^^^^^
42+
= note: `#[deny(missing_fragment_specifier)]` implied by `#[deny(future_incompatible)]`
2143

0 commit comments

Comments
 (0)