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.
1 parent ea8d4d7 commit e575792Copy full SHA for e575792
src/test/run-fail/small-negative-indexing.rs
@@ -0,0 +1,6 @@
1
+
2
+fn main() {
3
+ let v = vec::from_fn(1024u) {|n| n};
4
+ // this should trip a bounds check
5
+ log(error, v[-1i8]);
6
+}
0 commit comments