Explain why we shouldn't add inline attr to into_vec
This commit is contained in:
parent
339a938fa6
commit
1a46159828
|
@ -140,6 +140,9 @@ mod hack {
|
|||
use crate::string::ToString;
|
||||
use crate::vec::Vec;
|
||||
|
||||
// We shouldn't add inline attribute to this since this is used in
|
||||
// `vec!` macro mostly and causes perf regression. See #71204 for
|
||||
// discussion and perf results.
|
||||
pub fn into_vec<T>(b: Box<[T]>) -> Vec<T> {
|
||||
unsafe {
|
||||
let len = b.len();
|
||||
|
|
Loading…
Reference in New Issue