]> git.lizzy.rs Git - rust.git/blob - src/tools/rustfmt/tests/target/spaces-around-ranges.rs
Add 'compiler/rustc_codegen_gcc/' from commit 'afae271d5d3719eeb92c18bc004bb6d1965a5f3f'
[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 }