about summary refs log tree commit diff
diff options
context:
space:
mode:
authorStepan Koltsov <stepan.koltsov@gmail.com>2015-02-23 02:58:54 +0300
committerStepan Koltsov <stepan.koltsov@gmail.com>2015-02-23 02:58:54 +0300
commit554022e58392b173092e707b4c553713d07ed44d (patch)
tree82394ab43c4c3cc75a3022760ffdfe45c8e5424c
parent852eadc2951a2f94d2ede72c0e36033c8b754bd8 (diff)
downloadrust-554022e58392b173092e707b4c553713d07ed44d.tar.gz
rust-554022e58392b173092e707b4c553713d07ed44d.zip
boxed: mark from_raw and into_raw functions inline
-rw-r--r--src/liballoc/boxed.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/liballoc/boxed.rs b/src/liballoc/boxed.rs
index 75260e94327..befdf995701 100644
--- a/src/liballoc/boxed.rs
+++ b/src/liballoc/boxed.rs
@@ -114,6 +114,7 @@ impl<T : ?Sized> Box<T> {
     /// function is called twice on the same raw pointer.
     #[unstable(feature = "alloc",
                reason = "may be renamed or moved out of Box scope")]
+    #[inline]
     pub unsafe fn from_raw(raw: *mut T) -> Self {
         mem::transmute(raw)
     }
@@ -141,6 +142,7 @@ impl<T : ?Sized> Box<T> {
 /// ```
 #[unstable(feature = "alloc",
            reason = "may be renamed")]
+#[inline]
 pub unsafe fn into_raw<T : ?Sized>(b: Box<T>) -> *mut T {
     mem::transmute(b)
 }