diff options
| author | Dylan DPC <dylan.dpc@gmail.com> | 2020-09-07 01:17:45 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-09-07 01:17:45 +0200 |
| commit | e488c4f187be7f561ff24fcbdc8427767be79f1f (patch) | |
| tree | 987d83025304a2d36ee86467ca272e52fb651573 /src/test/ui/array-slice-vec/vec.rs | |
| parent | 73dc675b9437c2a51a975a9f58cc66f05463c351 (diff) | |
| parent | 2278c7255a1423b12d0efee3de43b23fa0d5b892 (diff) | |
| download | rust-e488c4f187be7f561ff24fcbdc8427767be79f1f.tar.gz rust-e488c4f187be7f561ff24fcbdc8427767be79f1f.zip | |
Rollup merge of #76273 - CraftSpider:master, r=matklad
Move some Vec UI tests into alloc unit tests A bit of work towards #76268, makes a number of the Vec UI tests that are simply running code into unit tests. Ensured that they are being run when testing liballoc locally.
Diffstat (limited to 'src/test/ui/array-slice-vec/vec.rs')
| -rw-r--r-- | src/test/ui/array-slice-vec/vec.rs | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/src/test/ui/array-slice-vec/vec.rs b/src/test/ui/array-slice-vec/vec.rs deleted file mode 100644 index e76c1ab440e..00000000000 --- a/src/test/ui/array-slice-vec/vec.rs +++ /dev/null @@ -1,15 +0,0 @@ -// run-pass - - - -pub fn main() { - let v: Vec<isize> = vec![10, 20]; - assert_eq!(v[0], 10); - assert_eq!(v[1], 20); - let mut x: usize = 0; - assert_eq!(v[x], 10); - assert_eq!(v[x + 1], 20); - x = x + 1; - assert_eq!(v[x], 20); - assert_eq!(v[x - 1], 10); -} |
