diff options
Diffstat (limited to '')
-rw-r--r-- | src/test/ui/issues/issue-51116.rs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/test/ui/issues/issue-51116.rs b/src/test/ui/issues/issue-51116.rs new file mode 100644 index 000000000..4c21cbfc6 --- /dev/null +++ b/src/test/ui/issues/issue-51116.rs @@ -0,0 +1,12 @@ +fn main() { + let tiles = Default::default(); + for row in &mut tiles { + for tile in row { + *tile = 0; + //~^ ERROR type annotations needed + //~| NOTE cannot infer type + } + } + + let tiles: [[usize; 3]; 3] = tiles; +} |