|
188 | 188 | //! [array]: prim@array
|
189 | 189 | //! [slice]: prim@slice
|
190 | 190 |
|
191 |
| -// To run libstd tests without x.py without ending up with two copies of libstd, Miri needs to be |
192 |
| -// able to "empty" this crate. See <https://github.com/rust-lang/miri-test-libstd/issues/4>. |
193 |
| -// rustc itself never sets the feature, so this line has no affect there. |
194 |
| -#![cfg(any(not(feature = "miri-test-libstd"), test, doctest))] |
195 |
| -// miri-test-libstd also prefers to make std use the sysroot versions of the dependencies. |
196 |
| -#![cfg_attr(feature = "miri-test-libstd", feature(rustc_private))] |
197 |
| -// |
198 | 191 | #![cfg_attr(not(feature = "restricted-std"), stable(feature = "rust1", since = "1.0.0"))]
|
199 | 192 | #![cfg_attr(feature = "restricted-std", unstable(feature = "restricted_std", issue = "none"))]
|
200 | 193 | #![doc(
|
|
209 | 202 | no_global_oom_handling,
|
210 | 203 | not(no_global_oom_handling)
|
211 | 204 | ))]
|
| 205 | +// To run libstd tests without x.py without ending up with two copies of libstd, Miri needs to be |
| 206 | +// able to "empty" this crate. See <https://github.com/rust-lang/miri-test-libstd/issues/4>. |
| 207 | +// rustc itself never sets the feature, so this line has no affect there. |
| 208 | +#![cfg(any(not(feature = "miri-test-libstd"), test, doctest))] |
| 209 | +// miri-test-libstd also prefers to make std use the sysroot versions of the dependencies. |
| 210 | +#![cfg_attr(feature = "miri-test-libstd", feature(rustc_private))] |
212 | 211 | // Don't link to std. We are std.
|
213 | 212 | #![no_std]
|
| 213 | +// Tell the compiler to link to either panic_abort or panic_unwind |
| 214 | +#![needs_panic_runtime] |
| 215 | +// |
| 216 | +// Lints: |
214 | 217 | #![warn(deprecated_in_future)]
|
215 | 218 | #![warn(missing_docs)]
|
216 | 219 | #![warn(missing_debug_implementations)]
|
217 | 220 | #![allow(explicit_outlives_requirements)]
|
218 | 221 | #![allow(unused_lifetimes)]
|
219 |
| -// Tell the compiler to link to either panic_abort or panic_unwind |
220 |
| -#![needs_panic_runtime] |
| 222 | +#![deny(rustc::existing_doc_keyword)] |
221 | 223 | // Ensure that std can be linked against panic_abort despite compiled with `-C panic=unwind`
|
222 | 224 | #![deny(ffi_unwind_calls)]
|
223 | 225 | // std may use features in a platform-specific way
|
224 | 226 | #![allow(unused_features)]
|
| 227 | +// |
| 228 | +// Features: |
225 | 229 | #![cfg_attr(test, feature(internal_output_capture, print_internals, update_panic_count, rt))]
|
226 | 230 | #![cfg_attr(
|
227 | 231 | all(target_vendor = "fortanix", target_env = "sgx"),
|
228 | 232 | feature(slice_index_methods, coerce_unsized, sgx_platform)
|
229 | 233 | )]
|
230 |
| -#![deny(rustc::existing_doc_keyword)] |
231 | 234 | //
|
232 | 235 | // Language features:
|
233 | 236 | #![feature(alloc_error_handler)]
|
|
0 commit comments