rustc_feature/
accepted.rs

1//! List of the accepted feature gates.
2
3use rustc_span::sym;
4
5use super::{Feature, to_nonzero};
6
7macro_rules! declare_features {
8    ($(
9        $(#[doc = $doc:tt])* (accepted, $feature:ident, $ver:expr, $issue:expr),
10    )+) => {
11        /// Formerly unstable features that have now been accepted (stabilized).
12        pub static ACCEPTED_LANG_FEATURES: &[Feature] = &[
13            $(Feature {
14                name: sym::$feature,
15                since: $ver,
16                issue: to_nonzero($issue),
17            }),+
18        ];
19    }
20}
21
22#[rustfmt::skip]
23declare_features! (
24    // -------------------------------------------------------------------------
25    // feature-group-start: for testing purposes
26    // -------------------------------------------------------------------------
27
28    /// A temporary feature gate used to enable parser extensions needed
29    /// to bootstrap fix for #5723.
30    (accepted, issue_5723_bootstrap, "1.0.0", None),
31    /// These are used to test this portion of the compiler,
32    /// they don't actually mean anything.
33    (accepted, test_accepted_feature, "1.0.0", None),
34    // !!!!    !!!!    !!!!    !!!!   !!!!    !!!!    !!!!    !!!!    !!!!    !!!!    !!!!
35    // Features are listed in alphabetical order. Tidy will fail if you don't keep it this way.
36    // !!!!    !!!!    !!!!    !!!!   !!!!    !!!!    !!!!    !!!!    !!!!    !!!!    !!!!
37
38    // -------------------------------------------------------------------------
39    // feature-group-end: for testing purposes
40    // -------------------------------------------------------------------------
41
42    // -------------------------------------------------------------------------
43    // feature-group-start: accepted features
44    // -------------------------------------------------------------------------
45
46    // Note that the version indicates when it got *stabilized*.
47    // When moving an unstable feature here, set the version number to
48    // `CURRENT RUSTC VERSION` with ` ` replaced by `_`.
49
50    /// Allows `#[target_feature(...)]` on aarch64 platforms
51    (accepted, aarch64_target_feature, "1.61.0", Some(44839)),
52    /// Allows using the `efiapi` ABI.
53    (accepted, abi_efiapi, "1.68.0", Some(65815)),
54    /// Allows the sysV64 ABI to be specified on all platforms
55    /// instead of just the platforms on which it is the C ABI.
56    (accepted, abi_sysv64, "1.24.0", Some(36167)),
57    /// Allows using the `thiscall` ABI.
58    (accepted, abi_thiscall, "1.73.0", None),
59    /// Allows using ADX intrinsics from `core::arch::{x86, x86_64}`.
60    (accepted, adx_target_feature, "1.61.0", Some(44839)),
61    /// Allows explicit discriminants on non-unit enum variants.
62    (accepted, arbitrary_enum_discriminant, "1.66.0", Some(60553)),
63    /// Allows using `const` operands in inline assembly.
64    (accepted, asm_const, "1.82.0", Some(93332)),
65    /// Allows using `label` operands in inline assembly.
66    (accepted, asm_goto, "CURRENT_RUSTC_VERSION", Some(119364)),
67    /// Allows using `sym` operands in inline assembly.
68    (accepted, asm_sym, "1.66.0", Some(93333)),
69    /// Allows the definition of associated constants in `trait` or `impl` blocks.
70    (accepted, associated_consts, "1.20.0", Some(29646)),
71    /// Allows the user of associated type bounds.
72    (accepted, associated_type_bounds, "1.79.0", Some(52662)),
73    /// Allows using associated `type`s in `trait`s.
74    (accepted, associated_types, "1.0.0", None),
75    /// Allows free and inherent `async fn`s, `async` blocks, and `<expr>.await` expressions.
76    (accepted, async_await, "1.39.0", Some(50547)),
77    /// Allows `async || body` closures.
78    (accepted, async_closure, "1.85.0", Some(62290)),
79    /// Allows async functions to be declared, implemented, and used in traits.
80    (accepted, async_fn_in_trait, "1.75.0", Some(91611)),
81    /// Allows all literals in attribute lists and values of key-value pairs.
82    (accepted, attr_literals, "1.30.0", Some(34981)),
83    /// Allows overloading augmented assignment operations like `a += b`.
84    (accepted, augmented_assignments, "1.8.0", Some(28235)),
85    /// Allows mixing bind-by-move in patterns and references to those identifiers in guards.
86    (accepted, bind_by_move_pattern_guards, "1.39.0", Some(15287)),
87    /// Allows bindings in the subpattern of a binding pattern.
88    /// For example, you can write `x @ Some(y)`.
89    (accepted, bindings_after_at, "1.56.0", Some(65490)),
90    /// Allows empty structs and enum variants with braces.
91    (accepted, braced_empty_structs, "1.8.0", Some(29720)),
92    /// Allows `c"foo"` literals.
93    (accepted, c_str_literals, "1.77.0", Some(105723)),
94    /// Allows `extern "C-unwind" fn` to enable unwinding across ABI boundaries and treat `extern "C" fn` as nounwind.
95    (accepted, c_unwind, "1.81.0", Some(74990)),
96    /// Allows `#[cfg_attr(predicate, multiple, attributes, here)]`.
97    (accepted, cfg_attr_multi, "1.33.0", Some(54881)),
98    /// Allows the use of `#[cfg(doctest)]`, set when rustdoc is collecting doctests.
99    (accepted, cfg_doctest, "1.40.0", Some(62210)),
100    /// Enables `#[cfg(panic = "...")]` config key.
101    (accepted, cfg_panic, "1.60.0", Some(77443)),
102    /// Allows `cfg(target_abi = "...")`.
103    (accepted, cfg_target_abi, "1.78.0", Some(80970)),
104    /// Allows `cfg(target_feature = "...")`.
105    (accepted, cfg_target_feature, "1.27.0", Some(29717)),
106    /// Allows `cfg(target_vendor = "...")`.
107    (accepted, cfg_target_vendor, "1.33.0", Some(29718)),
108    /// Allows implementing `Clone` for closures where possible (RFC 2132).
109    (accepted, clone_closures, "1.26.0", Some(44490)),
110    /// Allows coercing non capturing closures to function pointers.
111    (accepted, closure_to_fn_coercion, "1.19.0", Some(39817)),
112    /// Allows using the CMPXCHG16B target feature.
113    (accepted, cmpxchg16b_target_feature, "1.69.0", Some(44839)),
114    /// Allows use of the `#[collapse_debuginfo]` attribute.
115    (accepted, collapse_debuginfo, "1.79.0", Some(100758)),
116    /// Allows usage of the `compile_error!` macro.
117    (accepted, compile_error, "1.20.0", Some(40872)),
118    /// Allows `impl Trait` in function return types.
119    (accepted, conservative_impl_trait, "1.26.0", Some(34511)),
120    /// Allows calling constructor functions in `const fn`.
121    (accepted, const_constructor, "1.40.0", Some(61456)),
122    /// Allows the definition of `const extern fn` and `const unsafe extern fn`.
123    (accepted, const_extern_fn, "1.83.0", Some(64926)),
124    /// Allows basic arithmetic on floating point types in a `const fn`.
125    (accepted, const_fn_floating_point_arithmetic, "1.82.0", Some(57241)),
126    /// Allows using and casting function pointers in a `const fn`.
127    (accepted, const_fn_fn_ptr_basics, "1.61.0", Some(57563)),
128    /// Allows trait bounds in `const fn`.
129    (accepted, const_fn_trait_bound, "1.61.0", Some(93706)),
130    /// Allows calling `transmute` in const fn
131    (accepted, const_fn_transmute, "1.56.0", Some(53605)),
132    /// Allows accessing fields of unions inside `const` functions.
133    (accepted, const_fn_union, "1.56.0", Some(51909)),
134    /// Allows unsizing coercions in `const fn`.
135    (accepted, const_fn_unsize, "1.54.0", Some(64992)),
136    /// Allows const generics to have default values (e.g. `struct Foo<const N: usize = 3>(...);`).
137    (accepted, const_generics_defaults, "1.59.0", Some(44580)),
138    /// Allows the use of `if` and `match` in constants.
139    (accepted, const_if_match, "1.46.0", Some(49146)),
140    /// Allows argument and return position `impl Trait` in a `const fn`.
141    (accepted, const_impl_trait, "1.61.0", Some(77463)),
142    /// Allows indexing into constant arrays.
143    (accepted, const_indexing, "1.26.0", Some(29947)),
144    /// Allows let bindings, assignments and destructuring in `const` functions and constants.
145    /// As long as control flow is not implemented in const eval, `&&` and `||` may not be used
146    /// at the same time as let bindings.
147    (accepted, const_let, "1.33.0", Some(48821)),
148    /// Allows the use of `loop` and `while` in constants.
149    (accepted, const_loop, "1.46.0", Some(52000)),
150    /// Allows using `&mut` in constant functions.
151    (accepted, const_mut_refs, "1.83.0", Some(57349)),
152    /// Allows panicking during const eval (producing compile-time errors).
153    (accepted, const_panic, "1.57.0", Some(51999)),
154    /// Allows dereferencing raw pointers during const eval.
155    (accepted, const_raw_ptr_deref, "1.58.0", Some(51911)),
156    /// Allows references to types with interior mutability within constants
157    (accepted, const_refs_to_cell, "1.83.0", Some(80384)),
158    /// Allows creating pointers and references to `static` items in constants.
159    (accepted, const_refs_to_static, "1.83.0", Some(119618)),
160    /// Allows implementing `Copy` for closures where possible (RFC 2132).
161    (accepted, copy_closures, "1.26.0", Some(44490)),
162    /// Allows `crate` in paths.
163    (accepted, crate_in_paths, "1.30.0", Some(45477)),
164    /// Allows users to provide classes for fenced code block using `class:classname`.
165    (accepted, custom_code_classes_in_docs, "1.80.0", Some(79483)),
166    /// Allows using `#[debugger_visualizer]` attribute.
167    (accepted, debugger_visualizer, "1.71.0", Some(95939)),
168    /// Allows rustc to inject a default alloc_error_handler
169    (accepted, default_alloc_error_handler, "1.68.0", Some(66741)),
170    /// Allows using assigning a default type to type parameters in algebraic data type definitions.
171    (accepted, default_type_params, "1.0.0", None),
172    /// Allows `#[deprecated]` attribute.
173    (accepted, deprecated, "1.9.0", Some(29935)),
174    /// Allows `#[derive(Default)]` and `#[default]` on enums.
175    (accepted, derive_default_enum, "1.62.0", Some(86985)),
176    /// Allows the use of destructuring assignments.
177    (accepted, destructuring_assignment, "1.59.0", Some(71126)),
178    /// Allows using the `#[diagnostic]` attribute tool namespace
179    (accepted, diagnostic_namespace, "1.78.0", Some(111996)),
180    /// Controls errors in trait implementations.
181    (accepted, do_not_recommend, "1.85.0", Some(51992)),
182    /// Allows `#[doc(alias = "...")]`.
183    (accepted, doc_alias, "1.48.0", Some(50146)),
184    /// Allows `..` in tuple (struct) patterns.
185    (accepted, dotdot_in_tuple_patterns, "1.14.0", Some(33627)),
186    /// Allows `..=` in patterns (RFC 1192).
187    (accepted, dotdoteq_in_patterns, "1.26.0", Some(28237)),
188    /// Allows `Drop` types in constants (RFC 1440).
189    (accepted, drop_types_in_const, "1.22.0", Some(33156)),
190    /// Allows using `dyn Trait` as a syntax for trait objects.
191    (accepted, dyn_trait, "1.27.0", Some(44662)),
192    /// Allows `X..Y` patterns.
193    (accepted, exclusive_range_pattern, "1.80.0", Some(37854)),
194    /// Allows integer match exhaustiveness checking (RFC 2591).
195    (accepted, exhaustive_integer_patterns, "1.33.0", Some(50907)),
196    /// Allows explicit generic arguments specification with `impl Trait` present.
197    (accepted, explicit_generic_args_with_impl_trait, "1.63.0", Some(83701)),
198    /// Uses 2024 rules for matching `expr` fragments in macros. Also enables `expr_2021` fragment.
199    (accepted, expr_fragment_specifier_2024, "1.83.0", Some(123742)),
200    /// Allows arbitrary expressions in key-value attributes at parse time.
201    (accepted, extended_key_value_attributes, "1.54.0", Some(78835)),
202    /// Allows resolving absolute paths as paths from other crates.
203    (accepted, extern_absolute_paths, "1.30.0", Some(44660)),
204    /// Allows `extern crate foo as bar;`. This puts `bar` into extern prelude.
205    (accepted, extern_crate_item_prelude, "1.31.0", Some(55599)),
206    /// Allows `extern crate self as foo;`.
207    /// This puts local crate root into extern prelude under name `foo`.
208    (accepted, extern_crate_self, "1.34.0", Some(56409)),
209    /// Allows access to crate names passed via `--extern` through prelude.
210    (accepted, extern_prelude, "1.30.0", Some(44660)),
211    /// Allows using F16C intrinsics from `core::arch::{x86, x86_64}`.
212    (accepted, f16c_target_feature, "1.68.0", Some(44839)),
213    /// Allows field shorthands (`x` meaning `x: x`) in struct literal expressions.
214    (accepted, field_init_shorthand, "1.17.0", Some(37340)),
215    /// Allows `#[must_use]` on functions, and introduces must-use operators (RFC 1940).
216    (accepted, fn_must_use, "1.27.0", Some(43302)),
217    /// Allows capturing variables in scope using format_args!
218    (accepted, format_args_capture, "1.58.0", Some(67984)),
219    /// Allows associated types to be generic, e.g., `type Foo<T>;` (RFC 1598).
220    (accepted, generic_associated_types, "1.65.0", Some(44265)),
221    /// Allows attributes on lifetime/type formal parameters in generics (RFC 1327).
222    (accepted, generic_param_attrs, "1.27.0", Some(48848)),
223    /// Allows the `#[global_allocator]` attribute.
224    (accepted, global_allocator, "1.28.0", Some(27389)),
225    // FIXME: explain `globs`.
226    (accepted, globs, "1.0.0", None),
227    /// Allows using `..=X` as a pattern.
228    (accepted, half_open_range_patterns, "1.66.0", Some(67264)),
229    /// Allows using the `u128` and `i128` types.
230    (accepted, i128_type, "1.26.0", Some(35118)),
231    /// Allows the use of `if let` expressions.
232    (accepted, if_let, "1.0.0", None),
233    /// Rescoping temporaries in `if let` to align with Rust 2024.
234    (accepted, if_let_rescope, "1.84.0", Some(124085)),
235    /// Allows top level or-patterns (`p | q`) in `if let` and `while let`.
236    (accepted, if_while_or_patterns, "1.33.0", Some(48215)),
237    /// Allows lifetime elision in `impl` headers. For example:
238    /// + `impl<I:Iterator> Iterator for &mut Iterator`
239    /// + `impl Debug for Foo<'_>`
240    (accepted, impl_header_lifetime_elision, "1.31.0", Some(15872)),
241    /// Allows referencing `Self` and projections in impl-trait.
242    (accepted, impl_trait_projections, "1.74.0", Some(103532)),
243    /// Allows using imported `main` function
244    (accepted, imported_main, "1.79.0", Some(28937)),
245    /// Allows using `a..=b` and `..=b` as inclusive range syntaxes.
246    (accepted, inclusive_range_syntax, "1.26.0", Some(28237)),
247    /// Allows inferring outlives requirements (RFC 2093).
248    (accepted, infer_outlives_requirements, "1.30.0", Some(44493)),
249    /// Allow anonymous constants from an inline `const` block
250    (accepted, inline_const, "1.79.0", Some(76001)),
251    /// Allows irrefutable patterns in `if let` and `while let` statements (RFC 2086).
252    (accepted, irrefutable_let_patterns, "1.33.0", Some(44495)),
253    /// Allows `#[instruction_set(_)]` attribute.
254    (accepted, isa_attribute, "1.67.0", Some(74727)),
255    /// Allows some increased flexibility in the name resolution rules,
256    /// especially around globs and shadowing (RFC 1560).
257    (accepted, item_like_imports, "1.15.0", Some(35120)),
258    /// Allows `'a: { break 'a; }`.
259    (accepted, label_break_value, "1.65.0", Some(48594)),
260    /// Allows `let...else` statements.
261    (accepted, let_else, "1.65.0", Some(87335)),
262    /// Allows using `reason` in lint attributes and the `#[expect(lint)]` lint check.
263    (accepted, lint_reasons, "1.81.0", Some(54503)),
264    /// Allows `break {expr}` with a value inside `loop`s.
265    (accepted, loop_break_value, "1.19.0", Some(37339)),
266    /// Allows use of `?` as the Kleene "at most one" operator in macros.
267    (accepted, macro_at_most_once_rep, "1.32.0", Some(48075)),
268    /// Allows macro attributes to observe output of `#[derive]`.
269    (accepted, macro_attributes_in_derive_output, "1.57.0", Some(81119)),
270    /// Allows use of the `:lifetime` macro fragment specifier.
271    (accepted, macro_lifetime_matcher, "1.27.0", Some(34303)),
272    /// Allows use of the `:literal` macro fragment specifier (RFC 1576).
273    (accepted, macro_literal_matcher, "1.32.0", Some(35625)),
274    /// Allows `macro_rules!` items.
275    (accepted, macro_rules, "1.0.0", None),
276    /// Allows use of the `:vis` macro fragment specifier
277    (accepted, macro_vis_matcher, "1.30.0", Some(41022)),
278    /// Allows macro invocations in `extern {}` blocks.
279    (accepted, macros_in_extern, "1.40.0", Some(49476)),
280    /// Allows '|' at beginning of match arms (RFC 1925).
281    (accepted, match_beginning_vert, "1.25.0", Some(44101)),
282    /// Allows default match binding modes (RFC 2005).
283    (accepted, match_default_bindings, "1.26.0", Some(42640)),
284    /// Allows `impl Trait` with multiple unrelated lifetimes.
285    (accepted, member_constraints, "1.54.0", Some(61997)),
286    /// Allows the definition of `const fn` functions.
287    (accepted, min_const_fn, "1.31.0", Some(53555)),
288    /// The smallest useful subset of const generics.
289    (accepted, min_const_generics, "1.51.0", Some(74878)),
290    /// Allows calling `const unsafe fn` inside `unsafe` blocks in `const fn` functions.
291    (accepted, min_const_unsafe_fn, "1.33.0", Some(55607)),
292    /// Allows exhaustive pattern matching on uninhabited types when matched by value.
293    (accepted, min_exhaustive_patterns, "1.82.0", Some(119612)),
294    /// Allows using `Self` and associated types in struct expressions and patterns.
295    (accepted, more_struct_aliases, "1.16.0", Some(37544)),
296    /// Allows using the MOVBE target feature.
297    (accepted, movbe_target_feature, "1.70.0", Some(44839)),
298    /// Allows patterns with concurrent by-move and by-ref bindings.
299    /// For example, you can write `Foo(a, ref b)` where `a` is by-move and `b` is by-ref.
300    (accepted, move_ref_pattern, "1.49.0", Some(68354)),
301    /// Allows specifying modifiers in the link attribute: `#[link(modifiers = "...")]`
302    (accepted, native_link_modifiers, "1.61.0", Some(81490)),
303    /// Allows specifying the bundle link modifier
304    (accepted, native_link_modifiers_bundle, "1.63.0", Some(81490)),
305    /// Allows specifying the verbatim link modifier
306    (accepted, native_link_modifiers_verbatim, "1.67.0", Some(81490)),
307    /// Allows specifying the whole-archive link modifier
308    (accepted, native_link_modifiers_whole_archive, "1.61.0", Some(81490)),
309    /// Allows using non lexical lifetimes (RFC 2094).
310    (accepted, nll, "1.63.0", Some(43234)),
311    /// Allows using `#![no_std]`.
312    (accepted, no_std, "1.6.0", None),
313    /// Allows defining identifiers beyond ASCII.
314    (accepted, non_ascii_idents, "1.53.0", Some(55467)),
315    /// Allows future-proofing enums/structs with the `#[non_exhaustive]` attribute (RFC 2008).
316    (accepted, non_exhaustive, "1.40.0", Some(44109)),
317    /// Allows `foo.rs` as an alternative to `foo/mod.rs`.
318    (accepted, non_modrs_mods, "1.30.0", Some(44660)),
319    /// Allows using multiple nested field accesses in offset_of!
320    (accepted, offset_of_nested, "1.82.0", Some(120140)),
321    /// Allows the use of or-patterns (e.g., `0 | 1`).
322    (accepted, or_patterns, "1.53.0", Some(54883)),
323    /// Allows using `+bundle,+whole-archive` link modifiers with native libs.
324    (accepted, packed_bundled_libs, "1.74.0", Some(108081)),
325    /// Allows annotating functions conforming to `fn(&PanicInfo) -> !` with `#[panic_handler]`.
326    /// This defines the behavior of panics.
327    (accepted, panic_handler, "1.30.0", Some(44489)),
328    /// Allows attributes in formal function parameters.
329    (accepted, param_attrs, "1.39.0", Some(60406)),
330    /// Allows parentheses in patterns.
331    (accepted, pattern_parentheses, "1.31.0", Some(51087)),
332    /// Allows `use<'a, 'b, A, B>` in `impl Trait + use<...>` for precise capture of generic args.
333    (accepted, precise_capturing, "1.82.0", Some(123432)),
334    /// Allows `use<..>` precise capturign on impl Trait in traits.
335    (accepted, precise_capturing_in_traits, "CURRENT_RUSTC_VERSION", Some(130044)),
336    /// Allows procedural macros in `proc-macro` crates.
337    (accepted, proc_macro, "1.29.0", Some(38356)),
338    /// Allows multi-segment paths in attributes and derives.
339    (accepted, proc_macro_path_invoc, "1.30.0", Some(38356)),
340    /// Allows `pub(restricted)` visibilities (RFC 1422).
341    (accepted, pub_restricted, "1.18.0", Some(32409)),
342    /// Allows use of the postfix `?` operator in expressions.
343    (accepted, question_mark, "1.13.0", Some(31436)),
344    /// Allows the use of raw-dylibs (RFC 2627).
345    (accepted, raw_dylib, "1.71.0", Some(58713)),
346    /// Allows keywords to be escaped for use as identifiers.
347    (accepted, raw_identifiers, "1.30.0", Some(48589)),
348    /// Allows `&raw const $place_expr` and `&raw mut $place_expr` expressions.
349    (accepted, raw_ref_op, "1.82.0", Some(64490)),
350    /// Allows relaxing the coherence rules such that
351    /// `impl<T> ForeignTrait<LocalType> for ForeignType<T>` is permitted.
352    (accepted, re_rebalance_coherence, "1.41.0", Some(55437)),
353    /// Allows numeric fields in struct expressions and patterns.
354    (accepted, relaxed_adts, "1.19.0", Some(35626)),
355    /// Lessens the requirements for structs to implement `Unsize`.
356    (accepted, relaxed_struct_unsize, "1.58.0", Some(81793)),
357    /// Allows `repr(align(16))` struct attribute (RFC 1358).
358    (accepted, repr_align, "1.25.0", Some(33626)),
359    /// Allows using `#[repr(align(X))]` on enums with equivalent semantics
360    /// to wrapping an enum in a wrapper struct with `#[repr(align(X))]`.
361    (accepted, repr_align_enum, "1.37.0", Some(57996)),
362    /// Allows `#[repr(packed(N))]` attribute on structs.
363    (accepted, repr_packed, "1.33.0", Some(33158)),
364    /// Allows `#[repr(transparent)]` attribute on newtype structs.
365    (accepted, repr_transparent, "1.28.0", Some(43036)),
366    /// Allows enums like Result<T, E> to be used across FFI, if T's niche value can
367    /// be used to describe E or vice-versa.
368    (accepted, result_ffi_guarantees, "1.84.0", Some(110503)),
369    /// Allows return-position `impl Trait` in traits.
370    (accepted, return_position_impl_trait_in_trait, "1.75.0", Some(91611)),
371    /// Allows code like `let x: &'static u32 = &42` to work (RFC 1414).
372    (accepted, rvalue_static_promotion, "1.21.0", Some(38865)),
373    /// Allows `Self` in type definitions (RFC 2300).
374    (accepted, self_in_typedefs, "1.32.0", Some(49303)),
375    /// Allows `Self` struct constructor (RFC 2302).
376    (accepted, self_struct_ctor, "1.32.0", Some(51994)),
377    /// Shortern the tail expression lifetime
378    (accepted, shorter_tail_lifetimes, "1.84.0", Some(123739)),
379    /// Allows using subslice patterns, `[a, .., b]` and `[a, xs @ .., b]`.
380    (accepted, slice_patterns, "1.42.0", Some(62254)),
381    /// Allows use of `&foo[a..b]` as a slicing syntax.
382    (accepted, slicing_syntax, "1.0.0", None),
383    /// Allows elision of `'static` lifetimes in `static`s and `const`s.
384    (accepted, static_in_const, "1.17.0", Some(35897)),
385    /// Allows the definition recursive static items.
386    (accepted, static_recursion, "1.17.0", Some(29719)),
387    /// Allows attributes on struct literal fields.
388    (accepted, struct_field_attributes, "1.20.0", Some(38814)),
389    /// Allows struct variants `Foo { baz: u8, .. }` in enums (RFC 418).
390    (accepted, struct_variant, "1.0.0", None),
391    /// Allows `#[target_feature(...)]`.
392    (accepted, target_feature, "1.27.0", None),
393    /// Allows the use of `#[target_feature]` on safe functions.
394    (accepted, target_feature_11, "1.86.0", Some(69098)),
395    /// Allows `fn main()` with return types which implements `Termination` (RFC 1937).
396    (accepted, termination_trait, "1.26.0", Some(43301)),
397    /// Allows `#[test]` functions where the return type implements `Termination` (RFC 1937).
398    (accepted, termination_trait_test, "1.27.0", Some(48854)),
399    /// Allows attributes scoped to tools.
400    (accepted, tool_attributes, "1.30.0", Some(44690)),
401    /// Allows scoped lints.
402    (accepted, tool_lints, "1.31.0", Some(44690)),
403    /// Allows `#[track_caller]` to be used which provides
404    /// accurate caller location reporting during panic (RFC 2091).
405    (accepted, track_caller, "1.46.0", Some(47809)),
406    /// Allows dyn upcasting trait objects via supertraits.
407    /// Dyn upcasting is casting, e.g., `dyn Foo -> dyn Bar` where `Foo: Bar`.
408    (accepted, trait_upcasting, "1.86.0", Some(65991)),
409    /// Allows #[repr(transparent)] on univariant enums (RFC 2645).
410    (accepted, transparent_enums, "1.42.0", Some(60405)),
411    /// Allows indexing tuples.
412    (accepted, tuple_indexing, "1.0.0", None),
413    /// Allows paths to enum variants on type aliases including `Self`.
414    (accepted, type_alias_enum_variants, "1.37.0", Some(49683)),
415    /// Allows macros to appear in the type position.
416    (accepted, type_macros, "1.13.0", Some(27245)),
417    /// Allows using type privacy lints (`private_interfaces`, `private_bounds`, `unnameable_types`).
418    (accepted, type_privacy_lints, "1.79.0", Some(48054)),
419    /// Allows `const _: TYPE = VALUE`.
420    (accepted, underscore_const_names, "1.37.0", Some(54912)),
421    /// Allows `use path as _;` and `extern crate c as _;`.
422    (accepted, underscore_imports, "1.33.0", Some(48216)),
423    /// Allows `'_` placeholder lifetimes.
424    (accepted, underscore_lifetimes, "1.26.0", Some(44524)),
425    /// Allows `use x::y;` to search `x` in the current scope.
426    (accepted, uniform_paths, "1.32.0", Some(53130)),
427    /// Allows `impl Trait` in function arguments.
428    (accepted, universal_impl_trait, "1.26.0", Some(34511)),
429    /// Allows arbitrary delimited token streams in non-macro attributes.
430    (accepted, unrestricted_attribute_tokens, "1.34.0", Some(55208)),
431    /// Allows unsafe attributes.
432    (accepted, unsafe_attributes, "1.82.0", Some(123757)),
433    /// The `unsafe_op_in_unsafe_fn` lint (allowed by default): no longer treat an unsafe function as an unsafe block.
434    (accepted, unsafe_block_in_unsafe_fn, "1.52.0", Some(71668)),
435    /// Allows unsafe on extern declarations and safety qualifiers over internal items.
436    (accepted, unsafe_extern_blocks, "1.82.0", Some(123743)),
437    /// Allows importing and reexporting macros with `use`,
438    /// enables macro modularization in general.
439    (accepted, use_extern_macros, "1.30.0", Some(35896)),
440    /// Allows nested groups in `use` items (RFC 2128).
441    (accepted, use_nested_groups, "1.25.0", Some(44494)),
442    /// Allows `#[used]` to preserve symbols (see llvm.compiler.used).
443    (accepted, used, "1.30.0", Some(40289)),
444    /// Allows the use of `while let` expressions.
445    (accepted, while_let, "1.0.0", None),
446    /// Allows `#![windows_subsystem]`.
447    (accepted, windows_subsystem, "1.18.0", Some(37499)),
448    // !!!!    !!!!    !!!!    !!!!   !!!!    !!!!    !!!!    !!!!    !!!!    !!!!    !!!!
449    // Features are listed in alphabetical order. Tidy will fail if you don't keep it this way.
450    // !!!!    !!!!    !!!!    !!!!   !!!!    !!!!    !!!!    !!!!    !!!!    !!!!    !!!!
451
452    // -------------------------------------------------------------------------
453    // feature-group-end: accepted features
454    // -------------------------------------------------------------------------
455);