auto merge of #608 : kmcallister/servo/script-exit, r=metajack

This commit is contained in:
bors-servo 2013-07-22 13:33:20 -07:00
commit 25fdcb3dca
3 changed files with 10 additions and 13 deletions

View file

@ -223,6 +223,10 @@ impl<'self, View> AbstractNode<View> {
/// Sets the layout data, unsafely casting the type as layout wishes. Only layout is allowed
/// to call this. This is wildly unsafe and is therefore marked as such.
pub unsafe fn unsafe_set_layout_data<T>(self, data: @mut T) {
// Don't decrement the refcount on data, since we're giving it to the
// base structure.
cast::forget(data);
do self.with_mut_base |base| {
base.layout_data = Some(transmute(data))
}