diff options
Diffstat (limited to 'src/libsyntax/util/small_vector.rs')
| -rw-r--r-- | src/libsyntax/util/small_vector.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsyntax/util/small_vector.rs b/src/libsyntax/util/small_vector.rs index a3f081e7be4..60ba5f6615b 100644 --- a/src/libsyntax/util/small_vector.rs +++ b/src/libsyntax/util/small_vector.rs @@ -98,7 +98,7 @@ impl<T> SmallVector<T> { pub fn get<'a>(&'a self, idx: uint) -> &'a T { match self.repr { One(ref v) if idx == 0 => v, - Many(ref vs) => vs.get(idx), + Many(ref vs) => &vs[idx], _ => fail!("out of bounds access") } } |
