]> git.lizzy.rs Git - rust.git/blob - src/tools/rustfmt/tests/target/spaces-around-ranges.rs
Merge commit '0c89065b934397b62838fe3e4ef6f6352fc52daf' into libgccjit-codegen
[rust.git] / src / tools / rustfmt / tests / target / spaces-around-ranges.rs
1 // rustfmt-spaces_around_ranges: true
2
3 fn bar(v: &[u8]) {}
4
5 fn foo() {
6     let a = vec![0; 20];
7     for j in 0 ..= 20 {
8         for i in 0 .. 3 {
9             bar(a[i .. j]);
10             bar(a[i ..]);
11             bar(a[.. j]);
12             bar(a[..= (j + 1)]);
13         }
14     }
15 }