Skip to content

Commit

Permalink
bump const type id stabilization to 1.46.0
Browse files Browse the repository at this point in the history
  • Loading branch information
KodrAus committed Jul 28, 2020
1 parent cac16c9 commit e385661
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion library/core/src/any.rs
Original file line number Diff line number Diff line change
Expand Up @@ -435,7 +435,7 @@ impl TypeId {
/// assert_eq!(is_string(&"cookie monster".to_string()), true);
/// ```
#[stable(feature = "rust1", since = "1.0.0")]
#[rustc_const_stable(feature = "const_type_id", since = "1.45.0")]
#[rustc_const_stable(feature = "const_type_id", since = "1.46.0")]
pub const fn of<T: ?Sized + 'static>() -> TypeId {
TypeId { t: intrinsics::type_id::<T>() }
}
Expand Down
2 changes: 1 addition & 1 deletion library/core/src/intrinsics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1024,7 +1024,7 @@ extern "rust-intrinsic" {
///
/// The stabilized version of this intrinsic is
/// [`std::any::TypeId::of`](../../std/any/struct.TypeId.html#method.of)
#[rustc_const_stable(feature = "const_type_id", since = "1.45.0")]
#[rustc_const_stable(feature = "const_type_id", since = "1.46.0")]
pub fn type_id<T: ?Sized + 'static>() -> u64;

/// A guard for unsafe functions that cannot ever be executed if `T` is uninhabited:
Expand Down

0 comments on commit e385661

Please sign in to comment.