Skip to content

Commit a8a343a

Browse files
authored
Rollup merge of #58632 - matklad:reduce-contention, r=Centril
Make std feature list sorted This helps to avoid merge conflicts when concurrent PRs append features to the end of the list.
2 parents 40d40a3 + 88d55f5 commit a8a343a

File tree

1 file changed

+26
-23
lines changed

1 file changed

+26
-23
lines changed

Diff for: src/libstd/lib.rs

+26-23
Original file line numberDiff line numberDiff line change
@@ -215,16 +215,22 @@
215215
// std may use features in a platform-specific way
216216
#![allow(unused_features)]
217217

218+
#![cfg_attr(test, feature(test, update_panic_count))]
219+
#![cfg_attr(all(target_vendor = "fortanix", target_env = "sgx"),
220+
feature(global_asm, range_contains, slice_index_methods,
221+
decl_macro, coerce_unsized, sgx_platform, ptr_wrapping_offset_from))]
222+
218223
// std is implemented with unstable features, many of which are internal
219224
// compiler details that will never be stable
220-
#![cfg_attr(test, feature(test, update_panic_count))]
221-
#![feature(alloc)]
225+
// NB: the following list is sorted to minimize merge conflicts.
226+
#![feature(align_offset)]
222227
#![feature(alloc_error_handler)]
228+
#![feature(alloc_layout_extra)]
229+
#![feature(alloc)]
223230
#![feature(allocator_api)]
224231
#![feature(allocator_internals)]
225232
#![feature(allow_internal_unsafe)]
226233
#![feature(allow_internal_unstable)]
227-
#![feature(align_offset)]
228234
#![feature(arbitrary_self_types)]
229235
#![feature(array_error_internals)]
230236
#![feature(asm)]
@@ -233,72 +239,69 @@
233239
#![feature(cfg_target_has_atomic)]
234240
#![feature(cfg_target_thread_local)]
235241
#![feature(char_error_internals)]
242+
#![feature(checked_duration_since)]
236243
#![feature(compiler_builtins_lib)]
237244
#![feature(concat_idents)]
238-
#![feature(const_raw_ptr_deref)]
239245
#![feature(const_cstr_unchecked)]
246+
#![feature(const_raw_ptr_deref)]
240247
#![feature(core_intrinsics)]
248+
#![feature(doc_alias)]
249+
#![feature(doc_cfg)]
250+
#![feature(doc_keyword)]
251+
#![feature(doc_masked)]
252+
#![feature(doc_spotlight)]
241253
#![feature(dropck_eyepatch)]
242254
#![feature(duration_constants)]
243255
#![feature(exact_size_is_empty)]
256+
#![feature(exhaustive_patterns)]
244257
#![feature(external_doc)]
245258
#![feature(fixed_size_array)]
246259
#![feature(fn_traits)]
247260
#![feature(fnbox)]
248261
#![feature(futures_api)]
249262
#![feature(generator_trait)]
263+
#![feature(hash_raw_entry)]
250264
#![feature(hashmap_internals)]
251265
#![feature(int_error_internals)]
252266
#![feature(integer_atomics)]
253267
#![feature(lang_items)]
254268
#![feature(libc)]
255269
#![feature(link_args)]
256270
#![feature(linkage)]
271+
#![feature(maybe_uninit)]
257272
#![feature(needs_panic_runtime)]
258273
#![feature(never_type)]
259274
#![feature(nll)]
260-
#![feature(exhaustive_patterns)]
275+
#![feature(non_exhaustive)]
261276
#![feature(on_unimplemented)]
262277
#![feature(optin_builtin_traits)]
278+
#![feature(panic_info_message)]
263279
#![feature(panic_internals)]
264280
#![feature(panic_unwind)]
265281
#![feature(prelude_import)]
266282
#![feature(ptr_internals)]
267283
#![feature(raw)]
268-
#![feature(hash_raw_entry)]
284+
#![feature(renamed_spin_loop)]
269285
#![feature(rustc_attrs)]
270286
#![feature(rustc_const_unstable)]
271-
#![feature(std_internals)]
272-
#![feature(stdsimd)]
287+
#![feature(rustc_private)]
273288
#![feature(shrink_to)]
274289
#![feature(slice_concat_ext)]
275290
#![feature(slice_internals)]
276291
#![feature(slice_patterns)]
277292
#![feature(staged_api)]
293+
#![feature(std_internals)]
294+
#![feature(stdsimd)]
278295
#![feature(stmt_expr_attributes)]
279296
#![feature(str_internals)]
280-
#![feature(renamed_spin_loop)]
281-
#![feature(rustc_private)]
282297
#![feature(thread_local)]
283298
#![feature(toowned_clone_into)]
284299
#![feature(try_from)]
285300
#![feature(try_reserve)]
286301
#![feature(unboxed_closures)]
287302
#![feature(untagged_unions)]
288303
#![feature(unwind_attributes)]
289-
#![feature(doc_cfg)]
290-
#![feature(doc_masked)]
291-
#![feature(doc_spotlight)]
292-
#![feature(doc_alias)]
293-
#![feature(doc_keyword)]
294-
#![feature(panic_info_message)]
295-
#![feature(non_exhaustive)]
296-
#![feature(alloc_layout_extra)]
297-
#![feature(maybe_uninit)]
298-
#![feature(checked_duration_since)]
299-
#![cfg_attr(all(target_vendor = "fortanix", target_env = "sgx"),
300-
feature(global_asm, range_contains, slice_index_methods,
301-
decl_macro, coerce_unsized, sgx_platform, ptr_wrapping_offset_from))]
304+
// NB: the above list is sorted to minimize merge conflicts.
302305

303306
#![default_lib_allocator]
304307

0 commit comments

Comments
 (0)