summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/out_of_bounds_indexing/issue-3102.stderr
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools/clippy/tests/ui/out_of_bounds_indexing/issue-3102.stderr')
-rw-r--r--src/tools/clippy/tests/ui/out_of_bounds_indexing/issue-3102.stderr16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/tools/clippy/tests/ui/out_of_bounds_indexing/issue-3102.stderr b/src/tools/clippy/tests/ui/out_of_bounds_indexing/issue-3102.stderr
new file mode 100644
index 000000000..516c1df40
--- /dev/null
+++ b/src/tools/clippy/tests/ui/out_of_bounds_indexing/issue-3102.stderr
@@ -0,0 +1,16 @@
+error: range is out of bounds
+ --> $DIR/issue-3102.rs:9:13
+ |
+LL | &x[num..10]; // should trigger out of bounds error
+ | ^^
+ |
+ = note: `-D clippy::out-of-bounds-indexing` implied by `-D warnings`
+
+error: range is out of bounds
+ --> $DIR/issue-3102.rs:10:8
+ |
+LL | &x[10..num]; // should trigger out of bounds error
+ | ^^
+
+error: aborting due to 2 previous errors
+