Skip to content

Commit

Permalink
Auto merge of #24619 - nrc:rc-coerce, r=nikomatsakis
Browse files Browse the repository at this point in the history
r? @nikomatsakis (note a few TODOs left in the code where I wasn't sure about stuff).
  • Loading branch information
bors committed May 13, 2015
2 parents 30a42fa + b799cd8 commit fa43387
Show file tree
Hide file tree
Showing 53 changed files with 1,669 additions and 609 deletions.
8 changes: 8 additions & 0 deletions src/liballoc/boxed.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,11 @@ use core::ops::{Deref, DerefMut};
use core::ptr::{Unique};
use core::raw::{TraitObject};

#[cfg(not(stage0))]
use core::marker::Unsize;
#[cfg(not(stage0))]
use core::ops::CoerceUnsized;

/// A value that represents the heap. This is the default place that the `box`
/// keyword allocates into when no place is supplied.
///
Expand Down Expand Up @@ -390,3 +395,6 @@ impl<'a,A,R> FnOnce<A> for Box<FnBox<A,Output=R>+Send+'a> {
self.call_box(args)
}
}

#[cfg(not(stage0))]
impl<T: ?Sized+Unsize<U>, U: ?Sized> CoerceUnsized<Box<U>> for Box<T> {}
Loading

0 comments on commit fa43387

Please sign in to comment.