]> git.lizzy.rs Git - rust.git/commitdiff
Fix libcore unit tests in stage 0
authorSimon Sapin <simon.sapin@exyr.org>
Mon, 18 Jan 2021 19:45:34 +0000 (20:45 +0100)
committerSimon Sapin <simon.sapin@exyr.org>
Mon, 15 Feb 2021 13:27:48 +0000 (14:27 +0100)
library/core/tests/lib.rs
library/core/tests/ptr.rs

index f5035c9f16f9597dd12a1b33c030ea2556acf28d..b82cfe862904e4226d6d9d1d7b5e15a9dcba9af5 100644 (file)
@@ -68,7 +68,7 @@
 #![feature(option_result_unwrap_unchecked)]
 #![feature(option_unwrap_none)]
 #![feature(peekable_peek_mut)]
-#![feature(ptr_metadata)]
+#![cfg_attr(not(bootstrap), feature(ptr_metadata))]
 #![feature(once_cell)]
 #![feature(unsafe_block_in_unsafe_fn)]
 #![feature(unsized_tuple_coercion)]
index d594af991bf64e09b44133195ae691aa7c49206e..1cdcb8c97670d4fc9fcd35d8286b86de632ad91c 100644 (file)
@@ -1,5 +1,8 @@
 use core::cell::RefCell;
-use core::ptr::{self, *};
+#[cfg(not(bootstrap))]
+use core::ptr;
+use core::ptr::*;
+#[cfg(not(bootstrap))]
 use std::fmt::{Debug, Display};
 
 #[test]