diff options
| author | David Tolnay <dtolnay@gmail.com> | 2022-01-21 01:34:19 -0800 |
|---|---|---|
| committer | David Tolnay <dtolnay@gmail.com> | 2022-01-30 19:44:59 -0800 |
| commit | cb93e9c0ec6058df03e163fd7b3e652f7f22041d (patch) | |
| tree | 9e5cfb35aa449e9ac8e410d4bfca9e335f05ae89 /src/test/codegen | |
| parent | e58e7b10e13595b4df1b105bfb9ad03c8dee7832 (diff) | |
| download | rust-cb93e9c0ec6058df03e163fd7b3e652f7f22041d.tar.gz rust-cb93e9c0ec6058df03e163fd7b3e652f7f22041d.zip | |
Compute indent never relative to current column
Previously the pretty printer would compute indentation always relative
to whatever column a block begins at, like this:
fn demo(arg1: usize,
arg2: usize);
This is never the thing to do in the dominant contemporary Rust style.
Rustfmt's default and the style used by the vast majority of Rust
codebases is block indentation:
fn demo(
arg1: usize,
arg2: usize,
);
where every indentation level is a multiple of 4 spaces and each level
is indented relative to the indentation of the previous line, not the
position that the block starts in.
Diffstat (limited to 'src/test/codegen')
0 files changed, 0 insertions, 0 deletions
