about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2015-01-06 16:11:23 -0800
committerAlex Crichton <alex@alexcrichton.com>2015-01-06 16:12:28 -0800
commit24ccb34266c93a21b4cd1bef473c56087689c079 (patch)
treedfe5de372c938941300e632bdb44e46cfcb0e391
parent56a9e2fcd5f0b737df81a39b22f72a55c95b44a2 (diff)
downloadrust-24ccb34266c93a21b4cd1bef473c56087689c079.tar.gz
rust-24ccb34266c93a21b4cd1bef473c56087689c079.zip
Revert "Remove the unneeded Sized bound on TypeId creation"
This reverts commit 240423236906a2df976edd6065bbc595711b83c0.

Conflicts:
	src/libcore/intrinsics.rs
-rw-r--r--src/libcore/intrinsics.rs18
1 files changed, 1 insertions, 17 deletions
diff --git a/src/libcore/intrinsics.rs b/src/libcore/intrinsics.rs
index 24ebd1ac21a..822416a387e 100644
--- a/src/libcore/intrinsics.rs
+++ b/src/libcore/intrinsics.rs
@@ -42,9 +42,6 @@
 #![experimental]
 #![allow(missing_docs)]
 
-#[cfg(not(stage0))]
-use marker::Sized;
-
 pub type GlueFn = extern "Rust" fn(*const i8);
 
 #[lang="ty_desc"]
@@ -203,9 +200,6 @@ extern "rust-intrinsic" {
     /// Gets an identifier which is globally unique to the specified type. This
     /// function will return the same value for a type regardless of whichever
     /// crate it is invoked in.
-    #[cfg(not(stage0))]
-    pub fn type_id<T: ?Sized + 'static>() -> TypeId;
-    #[cfg(stage0)]
     pub fn type_id<T: 'static>() -> TypeId;
 
     /// Create a value initialized to zero.
@@ -556,19 +550,9 @@ pub struct TypeId {
 }
 
 impl TypeId {
-    /// Returns the `TypeId` of the type this generic function has been
-    /// instantiated with
-    #[cfg(stage0)]
+    /// Returns the `TypeId` of the type this generic function has been instantiated with
     pub fn of<T: 'static>() -> TypeId {
         unsafe { type_id::<T>() }
     }
-
-    /// Returns the `TypeId` of the type this generic function has been
-    /// instantiated with
-    #[cfg(not(stage0))]
-    pub fn of<T: ?Sized + 'static>() -> TypeId {
-        unsafe { type_id::<T>() }
-    }
-
     pub fn hash(&self) -> u64 { self.t }
 }