We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2db05f0 commit 45bdf9cCopy full SHA for 45bdf9c
src/liballoc/vec.rs
@@ -1532,7 +1532,7 @@ impl<T, I> Index<I> for Vec<T> where [T]: Index<I> {
1532
1533
#[inline]
1534
fn index(&self, index: I) -> &Self::Output {
1535
- // NB built-in indexing via `&[T]`
+ // NB indexing via implementation on slice
1536
&(**self)[index]
1537
}
1538
@@ -1542,7 +1542,7 @@ impl<T, I> Index<I> for Vec<T> where [T]: Index<I> {
1542
impl<T, I> IndexMut<I> for Vec<T> where [T]: IndexMut<I> {
1543
1544
fn index_mut(&mut self, index: I) -> &mut Self::Output {
1545
- // NB built-in indexing via `&mut [T]`
1546
&mut (**self)[index]
1547
1548
0 commit comments