take should really always be inlined

This commit is contained in:
Lokathor
2020-01-24 00:41:23 -07:00
parent 212bf713a8
commit 0f799c6b86
+1
View File
@@ -88,6 +88,7 @@ mod tinyvec;
pub use crate::tinyvec::*;
// TODO MSRV(1.40.0): Just call the normal `core::mem::take`
#[inline(always)]
fn take<T: Default>(from: &mut T) -> T {
replace(from, T::default())
}