Skip to content

Commit 66cdc47

Browse files
committed
Auto merge of rust-lang#79336 - camelid:rename-feature-oibit-to-auto, r=oli-obk
Rename `optin_builtin_traits` to `auto_traits` They were originally called "opt-in, built-in traits" (OIBITs), but people realized that the name was too confusing and a mouthful, and so they were renamed to just "auto traits". The feature flag's name wasn't updated, though, so that's what this PR does. There are some other spots in the compiler that still refer to OIBITs, but I don't think changing those now is worth it since they are internal and not particularly relevant to this PR. Also see <https://rust-lang.zulipchat.com/#narrow/stream/131828-t-compiler/topic/opt-in.2C.20built-in.20traits.20(auto.20traits).20feature.20name>. r? `@oli-obk` (feel free to re-assign if you're not the right reviewer for this)
2 parents d688086 + c0e2fbf commit 66cdc47

File tree

6 files changed

+17
-7
lines changed

6 files changed

+17
-7
lines changed

alloc/src/lib.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,8 @@
112112
#![feature(never_type)]
113113
#![feature(nll)]
114114
#![feature(nonnull_slice_from_raw_parts)]
115-
#![feature(optin_builtin_traits)]
115+
#![cfg_attr(bootstrap, feature(optin_builtin_traits))]
116+
#![cfg_attr(not(bootstrap), feature(auto_traits))]
116117
#![feature(or_patterns)]
117118
#![feature(pattern)]
118119
#![feature(ptr_internals)]

core/src/lib.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,8 @@
117117
#![feature(nll)]
118118
#![feature(exhaustive_patterns)]
119119
#![feature(no_core)]
120-
#![feature(optin_builtin_traits)]
120+
#![cfg_attr(bootstrap, feature(optin_builtin_traits))]
121+
#![cfg_attr(not(bootstrap), feature(auto_traits))]
121122
#![feature(or_patterns)]
122123
#![feature(prelude_import)]
123124
#![feature(repr_simd, platform_intrinsics)]

proc_macro/src/lib.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@
2828
#![feature(extern_types)]
2929
#![feature(in_band_lifetimes)]
3030
#![feature(negative_impls)]
31-
#![feature(optin_builtin_traits)]
31+
#![cfg_attr(bootstrap, feature(optin_builtin_traits))]
32+
#![cfg_attr(not(bootstrap), feature(auto_traits))]
3233
#![feature(restricted_std)]
3334
#![feature(rustc_attrs)]
3435
#![feature(min_specialization)]

rtstartup/rsbegin.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,13 @@
99
// headers or footers.
1010
//
1111
// Note that the actual module entry point is located in the C runtime startup
12-
// object (usually called `crtX.o), which then invokes initialization callbacks
12+
// object (usually called `crtX.o`), which then invokes initialization callbacks
1313
// of other runtime components (registered via yet another special image section).
1414

15-
#![feature(no_core, lang_items, optin_builtin_traits)]
15+
#![feature(no_core)]
16+
#![feature(lang_items)]
17+
#![cfg_attr(bootstrap, feature(optin_builtin_traits))]
18+
#![cfg_attr(not(bootstrap), feature(auto_traits))]
1619
#![crate_type = "rlib"]
1720
#![no_core]
1821
#![allow(non_camel_case_types)]

rtstartup/rsend.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
// See rsbegin.rs for details.
22

3-
#![feature(no_core, lang_items, optin_builtin_traits)]
3+
#![feature(no_core)]
4+
#![feature(lang_items)]
5+
#![cfg_attr(bootstrap, feature(optin_builtin_traits))]
6+
#![cfg_attr(not(bootstrap), feature(auto_traits))]
47
#![crate_type = "rlib"]
58
#![no_core]
69

std/src/lib.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,8 @@
286286
#![feature(nll)]
287287
#![feature(nonnull_slice_from_raw_parts)]
288288
#![feature(once_cell)]
289-
#![feature(optin_builtin_traits)]
289+
#![cfg_attr(bootstrap, feature(optin_builtin_traits))]
290+
#![cfg_attr(not(bootstrap), feature(auto_traits))]
290291
#![feature(or_patterns)]
291292
#![feature(panic_info_message)]
292293
#![feature(panic_internals)]

0 commit comments

Comments
 (0)