about summary refs log tree commit diff
path: root/src/libcore
diff options
context:
space:
mode:
authorFelix S. Klock II <pnkfelix@pnkfx.org>2018-04-20 17:07:58 +0200
committerFelix S. Klock II <pnkfelix@pnkfx.org>2018-04-20 18:09:28 +0200
commitfadabd6fbbfe1a401bbdd4ba0919b21ba4f7c5d2 (patch)
tree271fba7df00efddcfaec54a88dabbcf038158046 /src/libcore
parent1a4443995c91648460a5483ca8b7886cd04197e2 (diff)
downloadrust-fadabd6fbbfe1a401bbdd4ba0919b21ba4f7c5d2.tar.gz
rust-fadabd6fbbfe1a401bbdd4ba0919b21ba4f7c5d2.zip
Revert stabilization of `feature(never_type)`.
This commit is just covering the feature gate itself and the tests
that made direct use of `!` and thus need to opt back into the
feature.

A follow on commit brings back the other change that motivates the
revert: Namely, going back to the old rules for falling back to `()`.
Diffstat (limited to 'src/libcore')
-rw-r--r--src/libcore/clone.rs2
-rw-r--r--src/libcore/cmp.rs8
-rw-r--r--src/libcore/fmt/mod.rs4
-rw-r--r--src/libcore/lib.rs1
-rw-r--r--src/libcore/marker.rs2
5 files changed, 9 insertions, 8 deletions
diff --git a/src/libcore/clone.rs b/src/libcore/clone.rs
index 58a8439162c..f79f7351698 100644
--- a/src/libcore/clone.rs
+++ b/src/libcore/clone.rs
@@ -179,7 +179,7 @@ mod impls {
         bool char
     }
 
-    #[stable(feature = "never_type", since = "1.26.0")]
+    #[unstable(feature = "never_type", issue = "35121")]
     impl Clone for ! {
         #[inline]
         fn clone(&self) -> Self {
diff --git a/src/libcore/cmp.rs b/src/libcore/cmp.rs
index 3ae9b05b865..c91aa06609d 100644
--- a/src/libcore/cmp.rs
+++ b/src/libcore/cmp.rs
@@ -881,24 +881,24 @@ mod impls {
 
     ord_impl! { char usize u8 u16 u32 u64 u128 isize i8 i16 i32 i64 i128 }
 
-    #[stable(feature = "never_type", since = "1.26.0")]
+    #[unstable(feature = "never_type", issue = "35121")]
     impl PartialEq for ! {
         fn eq(&self, _: &!) -> bool {
             *self
         }
     }
 
-    #[stable(feature = "never_type", since = "1.26.0")]
+    #[unstable(feature = "never_type", issue = "35121")]
     impl Eq for ! {}
 
-    #[stable(feature = "never_type", since = "1.26.0")]
+    #[unstable(feature = "never_type", issue = "35121")]
     impl PartialOrd for ! {
         fn partial_cmp(&self, _: &!) -> Option<Ordering> {
             *self
         }
     }
 
-    #[stable(feature = "never_type", since = "1.26.0")]
+    #[unstable(feature = "never_type", issue = "35121")]
     impl Ord for ! {
         fn cmp(&self, _: &!) -> Ordering {
             *self
diff --git a/src/libcore/fmt/mod.rs b/src/libcore/fmt/mod.rs
index 277bef2bf66..a8430f14410 100644
--- a/src/libcore/fmt/mod.rs
+++ b/src/libcore/fmt/mod.rs
@@ -1780,14 +1780,14 @@ macro_rules! fmt_refs {
 
 fmt_refs! { Debug, Display, Octal, Binary, LowerHex, UpperHex, LowerExp, UpperExp }
 
-#[stable(feature = "never_type", since = "1.26.0")]
+#[unstable(feature = "never_type", issue = "35121")]
 impl Debug for ! {
     fn fmt(&self, _: &mut Formatter) -> Result {
         *self
     }
 }
 
-#[stable(feature = "never_type", since = "1.26.0")]
+#[unstable(feature = "never_type", issue = "35121")]
 impl Display for ! {
     fn fmt(&self, _: &mut Formatter) -> Result {
         *self
diff --git a/src/libcore/lib.rs b/src/libcore/lib.rs
index ea7a46f44ae..ac1a8091eb3 100644
--- a/src/libcore/lib.rs
+++ b/src/libcore/lib.rs
@@ -82,6 +82,7 @@
 #![feature(iterator_repeat_with)]
 #![feature(lang_items)]
 #![feature(link_llvm_intrinsics)]
+#![feature(never_type)]
 #![feature(exhaustive_patterns)]
 #![feature(macro_at_most_once_rep)]
 #![feature(no_core)]
diff --git a/src/libcore/marker.rs b/src/libcore/marker.rs
index 885aabe0806..feb689dbc1f 100644
--- a/src/libcore/marker.rs
+++ b/src/libcore/marker.rs
@@ -630,7 +630,7 @@ mod copy_impls {
         bool char
     }
 
-    #[stable(feature = "never_type", since = "1.26.0")]
+    #[unstable(feature = "never_type", issue = "35121")]
     impl Copy for ! {}
 
     #[stable(feature = "rust1", since = "1.0.0")]