From fbcdf2a383f6b17f80d8c285af3fa9739aaf223c Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Thu, 18 Aug 2022 18:07:35 -0400 Subject: clarify lib.rs attribute structure --- library/alloc/src/lib.rs | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'library/alloc') diff --git a/library/alloc/src/lib.rs b/library/alloc/src/lib.rs index a6f3593addc..aea84ac90c1 100644 --- a/library/alloc/src/lib.rs +++ b/library/alloc/src/lib.rs @@ -56,11 +56,6 @@ //! [`Rc`]: rc //! [`RefCell`]: core::cell -// To run liballoc tests without x.py without ending up with two copies of liballoc, Miri needs to be -// able to "empty" this crate. See . -// rustc itself never sets the feature, so this line has no affect there. -#![cfg(any(not(feature = "miri-test-libstd"), test, doctest))] -// #![allow(unused_attributes)] #![stable(feature = "alloc", since = "1.36.0")] #![doc( @@ -78,6 +73,10 @@ ))] #![no_std] #![needs_allocator] +// To run liballoc tests without x.py without ending up with two copies of liballoc, Miri needs to be +// able to "empty" this crate. See . +// rustc itself never sets the feature, so this line has no affect there. +#![cfg(any(not(feature = "miri-test-libstd"), test, doctest))] // // Lints: #![deny(unsafe_op_in_unsafe_fn)] -- cgit 1.4.1-3-g733a5