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 01364c4 + 417e4b4 commit 0bdac78Copy full SHA for 0bdac78
src/libcore/slice.rs
@@ -996,6 +996,15 @@ impl<'a, T> Collection for &'a [T] {
996
}
997
998
999
+#[experimental = "trait is experimental"]
1000
+impl<'a, T> Collection for &'a mut [T] {
1001
+ /// Returns the length of a vector
1002
+ #[inline]
1003
+ fn len(&self) -> uint {
1004
+ self.repr().len
1005
+ }
1006
+}
1007
+
1008
#[unstable = "waiting for DST"]
1009
impl<'a, T> Default for &'a [T] {
1010
fn default() -> &'a [T] { &[] }
0 commit comments