We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 7b97ffc + 5cfa60d commit 918e573Copy full SHA for 918e573
lib.rs
@@ -137,6 +137,16 @@ pub struct SmallVec<A: Array> {
137
}
138
139
impl<A: Array> SmallVec<A> {
140
+ #[inline]
141
+ pub fn new() -> SmallVec<A> {
142
+ unsafe {
143
+ SmallVec {
144
+ len: 0,
145
+ data: Inline { array: mem::zeroed() },
146
+ }
147
148
149
+
150
pub unsafe fn set_len(&mut self, new_len: usize) {
151
self.len = new_len
152
@@ -435,18 +445,6 @@ impl<A: Array> fmt::Debug for SmallVec<A> where A::Item: fmt::Debug {
435
445
436
446
437
447
438
-impl<A: Array> SmallVec<A> {
439
- #[inline]
440
- pub fn new() -> SmallVec<A> {
441
- unsafe {
442
- SmallVec {
443
- len: 0,
444
- data: Inline { array: mem::zeroed() },
- }
448
-}
449
-
450
impl<A: Array> Default for SmallVec<A> {
451
#[inline]
452
fn default() -> SmallVec<A> {
0 commit comments