Skip to content

Commit

Permalink
auto merge of #13015 : tbu-/rust/pr_remove_immut, r=alexcrichton
Browse files Browse the repository at this point in the history
Remove std::cast::transmute_immut_unsafe.
It can be done in safe code using `as *T`.
  • Loading branch information
bors committed Mar 20, 2014
2 parents 8e28520 + 9b588a9 commit 8cfef59
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions src/libstd/cast.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,12 +75,6 @@ pub unsafe fn transmute_mut_unsafe<T>(ptr: *T) -> *mut T {
transmute(ptr)
}

/// Coerce an immutable reference to be mutable.
#[inline]
pub unsafe fn transmute_immut_unsafe<T>(ptr: *mut T) -> *T {
transmute(ptr)
}

/// Coerce a mutable reference to have an arbitrary associated region.
#[inline]
pub unsafe fn transmute_mut_region<'a,'b,T>(ptr: &'a mut T) -> &'b mut T {
Expand Down

0 comments on commit 8cfef59

Please sign in to comment.