Skip to content

Commit 5b4cd1b

Browse files
committed
also make 'core_intrinsics' internal
1 parent d1583eb commit 5b4cd1b

File tree

4 files changed

+6
-2
lines changed

4 files changed

+6
-2
lines changed

compiler/rustc_feature/src/unstable.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -132,10 +132,12 @@ macro_rules! declare_features {
132132
// Accepted/removed features aren't in this file but are never internal
133133
// (a removed feature might have been internal, but that's now irrelevant).
134134
// Libs features are internal if they end in `_internal` or `_internals`.
135+
// As a special exception we also consider `core_intrinsics` internal;
136+
// renaming that age-old feature is just not worth the hassle.
135137
// We just always test the name; it's not a big deal if we accidentally hit
136138
// an accepted/removed lang feature that way.
137139
let name = feature.as_str();
138-
name.ends_with("_internal") || name.ends_with("_internals")
140+
name == "core_intrinsics" || name.ends_with("_internal") || name.ends_with("_internals")
139141
}
140142
_ => panic!("`{}` was not listed in `declare_features`", feature),
141143
}

compiler/rustc_query_system/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
#![feature(hash_raw_entry)]
44
#![feature(min_specialization)]
55
#![feature(let_chains)]
6-
#![allow(rustc::potential_query_instability)]
6+
#![allow(rustc::potential_query_instability, internal_features)]
77
#![deny(rustc::untranslatable_diagnostic)]
88
#![deny(rustc::diagnostic_outside_of_impl)]
99

library/alloc/tests/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@
4040
#![feature(thin_box)]
4141
#![feature(strict_provenance)]
4242
#![feature(drain_keep_rest)]
43+
#![allow(internal_features)]
4344
#![deny(fuzzy_provenance_casts)]
4445
#![deny(unsafe_op_in_unsafe_fn)]
4546

library/core/tests/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,7 @@
116116
#![feature(get_many_mut)]
117117
#![feature(offset_of)]
118118
#![feature(iter_map_windows)]
119+
#![allow(internal_features)]
119120
#![deny(unsafe_op_in_unsafe_fn)]
120121
#![deny(fuzzy_provenance_casts)]
121122

0 commit comments

Comments
 (0)