diff options
| author | kennytm <kennytm@gmail.com> | 2018-12-07 12:42:32 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-12-07 12:42:32 +0800 |
| commit | 0e41ef13aac432d7c33f9e1287270769deb69c3f (patch) | |
| tree | 4bf4ba43ba7add944b6e078511960fbf1876dc9c /src/liballoc/tests/binary_heap.rs | |
| parent | 6a07f23c78dde6368e4566218aef4c38d9d64ec6 (diff) | |
| parent | c025d6140999e07ddf0294f0676c64ff2322a210 (diff) | |
| download | rust-0e41ef13aac432d7c33f9e1287270769deb69c3f.tar.gz rust-0e41ef13aac432d7c33f9e1287270769deb69c3f.zip | |
Rollup merge of #56516 - frewsxcv:frewsxcv-eq, r=Mark-Simulacrum
Replace usages of `..i + 1` ranges with `..=i`. Before this change we were using old computer code techniques. After this change we use the new and improved computer code techniques.
Diffstat (limited to 'src/liballoc/tests/binary_heap.rs')
| -rw-r--r-- | src/liballoc/tests/binary_heap.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/liballoc/tests/binary_heap.rs b/src/liballoc/tests/binary_heap.rs index 8494463463c..b0d8fa6bd69 100644 --- a/src/liballoc/tests/binary_heap.rs +++ b/src/liballoc/tests/binary_heap.rs @@ -318,11 +318,11 @@ fn panic_safe() { const NTEST: usize = 10; // don't use 0 in the data -- we want to catch the zeroed-out case. - let data = (1..DATASZ + 1).collect::<Vec<_>>(); + let data = (1..=DATASZ).collect::<Vec<_>>(); // since it's a fuzzy test, run several tries. for _ in 0..NTEST { - for i in 1..DATASZ + 1 { + for i in 1..=DATASZ { DROP_COUNTER.store(0, Ordering::SeqCst); let mut panic_ords: Vec<_> = data.iter() |
