]> git.lizzy.rs Git - rust.git/blobdiff - src/test/compile-fail/borrowck-overloaded-index-autoderef.rs
make `IndexMut` a super trait over `Index`
[rust.git] / src / test / compile-fail / borrowck-overloaded-index-autoderef.rs
index 977c67b1c7dbd073b03c2f53b238010433c982b9..99f396ef8143213af415dbca2a649d0b4e1cd167 100644 (file)
@@ -31,8 +31,6 @@ fn index<'a>(&'a self, z: &String) -> &'a isize {
 }
 
 impl IndexMut<String> for Foo {
-    type Output = isize;
-
     fn index_mut<'a>(&'a mut self, z: &String) -> &'a mut isize {
         if *z == "x" {
             &mut self.x