-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make
core_miri_test
and alloc_miri_test
empty when not collecting…
… doctests
- Loading branch information
hyd-dev
committed
Jul 18, 2021
1 parent
65a1fe7
commit ee0fd6c
Showing
3 changed files
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
diff --git a/library/alloc/src/lib.rs b/library/alloc/src/lib.rs | ||
index e8bd4bcb..cc518cc4 100644 | ||
--- a/library/alloc/src/lib.rs | ||
+++ b/library/alloc/src/lib.rs | ||
@@ -56,6 +56,7 @@ | ||
//! [`Rc`]: rc | ||
//! [`RefCell`]: core::cell | ||
|
||
+#![cfg(any(not(feature = "miri-test"), doctest))] | ||
#![allow(unused_attributes)] | ||
#![stable(feature = "alloc", since = "1.36.0")] | ||
#![doc( | ||
diff --git a/library/core/src/lib.rs b/library/core/src/lib.rs | ||
index 3557dbad..6c089b0c 100644 | ||
--- a/library/core/src/lib.rs | ||
+++ b/library/core/src/lib.rs | ||
@@ -49,6 +49,7 @@ | ||
// | ||
// This cfg won't affect doc tests. | ||
#![cfg(not(test))] | ||
+#![cfg(any(not(feature = "miri-test"), doctest))] | ||
#![stable(feature = "core", since = "1.6.0")] | ||
#![doc( | ||
html_playground_url = "https://play.rust-lang.org/", |