Skip to content

Commit 81ee92c

Browse files
committed
Remove sanitizer_runtime attribute
1 parent 4dcd723 commit 81ee92c

File tree

13 files changed

+2
-43
lines changed

13 files changed

+2
-43
lines changed

src/doc/unstable-book/src/library-features/sanitizer-runtime-lib.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

src/librustc/query/mod.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -661,10 +661,6 @@ rustc_queries! {
661661
fatal_cycle
662662
desc { "checking if the crate has_panic_handler" }
663663
}
664-
query is_sanitizer_runtime(_: CrateNum) -> bool {
665-
fatal_cycle
666-
desc { "query a crate is `#![sanitizer_runtime]`" }
667-
}
668664
query is_profiler_runtime(_: CrateNum) -> bool {
669665
fatal_cycle
670666
desc { "query a crate is `#![profiler_runtime]`" }

src/librustc_codegen_ssa/base.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -720,7 +720,6 @@ impl CrateInfo {
720720
panic_runtime: None,
721721
compiler_builtins: None,
722722
profiler_runtime: None,
723-
sanitizer_runtime: None,
724723
is_no_builtins: Default::default(),
725724
native_libraries: Default::default(),
726725
used_libraries: tcx.native_libraries(LOCAL_CRATE),
@@ -756,9 +755,6 @@ impl CrateInfo {
756755
if tcx.is_profiler_runtime(cnum) {
757756
info.profiler_runtime = Some(cnum);
758757
}
759-
if tcx.is_sanitizer_runtime(cnum) {
760-
info.sanitizer_runtime = Some(cnum);
761-
}
762758
if tcx.is_no_builtins(cnum) {
763759
info.is_no_builtins.insert(cnum);
764760
}

src/librustc_codegen_ssa/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,6 @@ pub struct CrateInfo {
130130
pub panic_runtime: Option<CrateNum>,
131131
pub compiler_builtins: Option<CrateNum>,
132132
pub profiler_runtime: Option<CrateNum>,
133-
pub sanitizer_runtime: Option<CrateNum>,
134133
pub is_no_builtins: FxHashSet<CrateNum>,
135134
pub native_libraries: FxHashMap<CrateNum, Lrc<Vec<NativeLibrary>>>,
136135
pub crate_name: FxHashMap<CrateNum, String>,

src/librustc_feature/active.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -184,9 +184,6 @@ declare_features! (
184184
/// Allows using the `unadjusted` ABI; perma-unstable.
185185
(active, abi_unadjusted, "1.16.0", None, None),
186186

187-
/// Allows identifying crates that contain sanitizer runtimes.
188-
(active, sanitizer_runtime, "1.17.0", None, None),
189-
190187
/// Used to identify crates that contain the profiler runtime.
191188
(active, profiler_runtime, "1.18.0", None, None),
192189

src/librustc_feature/builtin_attrs.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -398,11 +398,6 @@ pub const BUILTIN_ATTRIBUTES: &[BuiltinAttribute] = &[
398398
"the `#[compiler_builtins]` attribute is used to identify the `compiler_builtins` crate \
399399
which contains compiler-rt intrinsics and will never be stable",
400400
),
401-
gated!(
402-
sanitizer_runtime, Whitelisted, template!(Word),
403-
"the `#[sanitizer_runtime]` attribute is used to identify crates that contain the runtime \
404-
of a sanitizer and will never be stable",
405-
),
406401
gated!(
407402
profiler_runtime, Whitelisted, template!(Word),
408403
"the `#[profiler_runtime]` attribute is used to identify the `profiler_builtins` crate \

src/librustc_feature/removed.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@ declare_features! (
7373
(removed, pushpop_unsafe, "1.2.0", None, None, None),
7474
(removed, needs_allocator, "1.4.0", Some(27389), None,
7575
Some("subsumed by `#![feature(allocator_internals)]`")),
76+
/// Allows identifying crates that contain sanitizer runtimes.
77+
(removed, sanitizer_runtime, "1.17.0", None, None, None),
7678
(removed, proc_macro_mod, "1.27.0", Some(54727), None,
7779
Some("subsumed by `#![feature(proc_macro_hygiene)]`")),
7880
(removed, proc_macro_expr, "1.27.0", Some(54727), None,

src/librustc_metadata/rmeta/decoder.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1580,10 +1580,6 @@ impl<'a, 'tcx> CrateMetadata {
15801580
self.root.panic_runtime
15811581
}
15821582

1583-
crate fn is_sanitizer_runtime(&self) -> bool {
1584-
self.root.sanitizer_runtime
1585-
}
1586-
15871583
crate fn is_profiler_runtime(&self) -> bool {
15881584
self.root.profiler_runtime
15891585
}

src/librustc_metadata/rmeta/decoder/cstore_impl.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,6 @@ provide! { <'tcx> tcx, def_id, other, cdata,
153153
is_compiler_builtins => { cdata.root.compiler_builtins }
154154
has_global_allocator => { cdata.root.has_global_allocator }
155155
has_panic_handler => { cdata.root.has_panic_handler }
156-
is_sanitizer_runtime => { cdata.root.sanitizer_runtime }
157156
is_profiler_runtime => { cdata.root.profiler_runtime }
158157
panic_strategy => { cdata.root.panic_strategy }
159158
extern_crate => {

src/librustc_metadata/rmeta/encoder.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -527,7 +527,6 @@ impl<'tcx> EncodeContext<'tcx> {
527527
no_builtins: attr::contains_name(&attrs, sym::no_builtins),
528528
panic_runtime: attr::contains_name(&attrs, sym::panic_runtime),
529529
profiler_runtime: attr::contains_name(&attrs, sym::profiler_runtime),
530-
sanitizer_runtime: attr::contains_name(&attrs, sym::sanitizer_runtime),
531530
symbol_mangling_version: tcx.sess.opts.debugging_opts.symbol_mangling_version,
532531

533532
crate_deps,

src/librustc_metadata/rmeta/mod.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,6 @@ crate struct CrateRoot<'tcx> {
212212
no_builtins: bool,
213213
panic_runtime: bool,
214214
profiler_runtime: bool,
215-
sanitizer_runtime: bool,
216215
symbol_mangling_version: SymbolManglingVersion,
217216
}
218217

src/test/ui/feature-gates/feature-gate-sanitizer-runtime.rs

Lines changed: 0 additions & 3 deletions
This file was deleted.

src/test/ui/feature-gates/feature-gate-sanitizer-runtime.stderr

Lines changed: 0 additions & 11 deletions
This file was deleted.

0 commit comments

Comments
 (0)