Skip to content

Commit b124b36

Browse files
committed
sudo CI=green && Review changes <3
1 parent d9e32a6 commit b124b36

File tree

6 files changed

+8
-18
lines changed

6 files changed

+8
-18
lines changed

compiler/rustc_builtin_macros/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,14 @@
55
#![allow(internal_features)]
66
#![allow(rustc::diagnostic_outside_of_impl)]
77
#![allow(rustc::untranslatable_diagnostic)]
8+
#![cfg_attr(bootstrap, feature(lint_reasons))]
89
#![doc(html_root_url = "https://doc.rust-lang.org/nightly/nightly-rustc/")]
910
#![doc(rust_logo)]
1011
#![feature(assert_matches)]
1112
#![feature(box_patterns)]
1213
#![feature(decl_macro)]
1314
#![feature(if_let_guard)]
1415
#![feature(let_chains)]
15-
#![cfg_attr(bootstrap, feature(lint_reasons))]
1616
#![feature(proc_macro_internals)]
1717
#![feature(proc_macro_quote)]
1818
#![feature(rustdoc_internals)]

compiler/rustc_lint_defs/src/builtin.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -608,7 +608,7 @@ declare_lint! {
608608
}
609609

610610
declare_lint! {
611-
/// The `unfulfilled_lint_expectations` lint warns if a lint expectation is
611+
/// The `unfulfilled_lint_expectations` lint detects when a lint expectation is
612612
/// unfulfilled.
613613
///
614614
/// ### Example

src/doc/rustc/src/lints/levels.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -47,8 +47,8 @@ fn main() {
4747
#[expect(unused_variables)]
4848
let unused = "Everyone ignores me";
4949

50-
#[expect(unused_variables)]
51-
let used = "I'm useful";
50+
#[expect(unused_variables)] // `unused_variables` lint is not emitted
51+
let used = "I'm useful"; // the expectation is therefore unfulfilled
5252
println!("The `used` value is equal to: {:?}", used);
5353
}
5454
```
@@ -65,8 +65,8 @@ warning: this lint expectation is unfulfilled
6565
= note: `#[warn(unfulfilled_lint_expectations)]` on by default
6666
```
6767

68-
This level can only be defined via the `#[expect]` attribute and not via the
69-
console. Lints with the special 'force-warn' lint will still be emitted as usual.
68+
This level can only be defined via the `#[expect]` attribute, there is no equivalent
69+
flag. Lints with the special 'force-warn' level will still be emitted as usual.
7070

7171
## warn
7272

src/tools/clippy/tests/ui-toml/macro_metavars_in_unsafe/default/test.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//! Tests macro_metavars_in_unsafe with default configuration
2-
#![feature(decl_macro, lint_reasons)]
2+
#![feature(decl_macro)]
33
#![warn(clippy::macro_metavars_in_unsafe)]
44
#![allow(clippy::no_effect)]
55

src/tools/clippy/tests/ui-toml/macro_metavars_in_unsafe/default/test.stderr

+1-10
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,3 @@
1-
error: the feature `lint_reasons` has been stable since 1.81.0-dev and no longer requires an attribute to enable
2-
--> tests/ui-toml/macro_metavars_in_unsafe/default/test.rs:2:24
3-
|
4-
LL | #![feature(decl_macro, lint_reasons)]
5-
| ^^^^^^^^^^^^
6-
|
7-
= note: `-D stable-features` implied by `-D warnings`
8-
= help: to override `-D warnings` add `#[allow(stable_features)]`
9-
101
error: this macro expands metavariables in an unsafe block
112
--> tests/ui-toml/macro_metavars_in_unsafe/default/test.rs:19:9
123
|
@@ -192,5 +183,5 @@ LL | | }
192183
= help: consider expanding any metavariables outside of this block, e.g. by storing them in a variable
193184
= help: ... or also expand referenced metavariables in a safe context to require an unsafe block at callsite
194185

195-
error: aborting due to 15 previous errors
186+
error: aborting due to 14 previous errors
196187

tests/ui/sse2.rs

-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
#![allow(stable_features)]
44
#![feature(cfg_target_feature)]
5-
#![feature(lint_reasons)]
65

76
use std::env;
87

0 commit comments

Comments
 (0)