Nick Cameron
3b23a98d00
Support unstable options
...
cc #1976
2018-05-14 10:20:51 +12:00
Nick Cameron
5d9f5aa05a
Replace --write-mode
with --emit
...
cc #1976
2018-05-13 14:13:24 +12:00
Nick Cameron
8396da1882
Add --backup
flag
2018-05-13 13:18:08 +12:00
Nick Cameron
a8e7a7c8b8
Merge pull request #2700 from Pazzaz/master
...
Remove unnecessary use of Box in `format_function_type`
2018-05-13 10:04:38 +12:00
Nick Cameron
c34a387eb7
Merge pull request #2702 from andjo403/bump
...
Update regex, assert_cli, env_logger, rustc-ap-{rustc_target, syntax}
2018-05-13 10:03:19 +12:00
Andreas Jonson
195395f166
Update regex, assert_cli, env_logger, rustc-ap-{rustc_target, syntax}
...
this update removes 15 dependencies
2018-05-12 18:58:27 +02:00
Pazzaz
1c1763c7ae
Remove unnecessary use of Box in format_function_type
2018-05-12 10:53:06 +02:00
Seiichi Uchida
1b1eccc553
Fix build failure ( #2699 )
2018-05-12 10:36:34 +09:00
Seiichi Uchida
788c52ae74
Merge pull request #2693 from gnzlbg/integration
...
Add integration tests against crates in the rust-lang-nursery
2018-05-11 22:12:37 +09:00
Nick Cameron
eca7796fb1
Replace --dump-minimal-config
and --dump-default-config
with --print-config
...
cc #1976
2018-05-11 20:43:08 +12:00
Nick Cameron
4d9de48e06
Add --check
flag.
...
cc #1976
2018-05-11 20:26:00 +12:00
Nick Cameron
798bffb8b1
--help
options
...
cc #1976
2018-05-11 20:12:16 +12:00
Nick Cameron
1869888b1a
Remove --verbose-diff
...
Use `--verbose` instead
cc #1976
2018-05-11 13:58:34 +12:00
Nick Cameron
55ac062da0
Add --quiet
flag, remove Plain
write mode
...
cc #1976
2018-05-11 13:50:30 +12:00
gnzlbg
c79f39af16
Add integration tests against crates in the rust-lang-nursery
...
This commit adds integration tests against some crates in the
nursery.
Each integration test is added as a separate build-bot, where
the rust-lang-nursery/${CRATE} is first downloaded and its tests run.
Afterwards, `cargo fmt --all` is applied to the crate, and the tests
are re-run. If the tests fail after formatting, the integration test
fails.
The crates that currently fail are added as allowed-to-fail, but the
intent is that either these crates or rustfmt should be fixed such
that the tests pass.
2018-05-10 00:31:55 +02:00
Nick Cameron
5dba81bbbf
Merge pull request #2687 from Marwes/issue_2641
...
fix: Don't insert an extra brace in macros with native newlines
2018-05-09 13:18:27 +12:00
Nick Cameron
659d0c9741
Merge pull request #2684 from topecongiro/issue-2175
...
Apply small parent heuristic only when the chain is at the beginning of the line
2018-05-09 13:16:26 +12:00
Nick Cameron
d98a1ca9f5
Merge pull request #2689 from alexcrichton/fix-beta
...
Ensure tests pass on the beta compiler
2018-05-09 13:14:59 +12:00
Alex Crichton
47742807f7
Ensure tests pass on the beta compiler
...
Also add a travis matrix entry for emulating the beta tests
2018-05-08 18:05:08 -07:00
Nick Cameron
f8aed3d71a
Merge pull request #2685 from alexcrichton/fix-tests
...
Fix rustfmt tests in the Rust repo
2018-05-09 08:54:11 +12:00
Markus Westerlind
4c9ef93df7
fix: Don't insert an extra brace in macros with native newlines
...
Due to `format_snippet` formatting the input with \r\n the subtraction
would wouldn't give a length that removed the }
Fixes #2641
2018-05-08 20:34:44 +02:00
Alex Crichton
a72be170d7
Fix rustfmt tests in the Rust repo
...
Two tests were executing `cargo run` but `cargo` is not ambiently available to
execute. Instead it's best to execute the rustfmt binary directly, which is
always assembled as part of `cargo test`.
2018-05-08 07:32:00 -07:00
topecongiro
bd25c7d0f7
Cargo fmt
2018-05-08 06:25:48 +09:00
topecongiro
0ec311ee07
Apply small parent rule only when there is small offset
2018-05-08 06:25:06 +09:00
topecongiro
680c65dc97
Update tests to use the absolute position for small parent heuristic
2018-05-08 06:23:14 +09:00
Nick Cameron
f46f4b5f66
Merge pull request #2675 from flodiebold/non-modrs-mods
...
Fix handling of modules in non_modrs_mods style
2018-05-07 11:23:14 +12:00
Nick Cameron
bd7ae5e89b
Merge pull request #2682 from topecongiro/issue-2670
...
Do not duplicate attributes on use items
2018-05-07 11:21:02 +12:00
Nick Cameron
4bbd5c4ae5
Merge pull request #2681 from topecongiro/issue-2680
...
Error on self_tests when there are lines that exceed max width
2018-05-07 11:20:33 +12:00
Nick Cameron
effba718b4
Merge pull request #2679 from topecongiro/multi-lined-binary
...
Put operands on its own line when each fits in a single line
2018-05-07 10:54:49 +12:00
Nick Cameron
195489d4f0
Merge pull request #2683 from dzamlo/master
...
Update README.md to reflect change in #2539
2018-05-07 10:44:00 +12:00
Loïc Damien
c2ebb06a85
Update README.md to reflect change in #2539
2018-05-06 18:51:26 +02:00
Florian Diebold
e65aa302d3
Turn the nonmodrs-mods test into a standard idempotence test
...
We need to skip children on foo.rs, since the parser will not find bar from that
file, but with that, the test works fine.
2018-05-06 13:08:43 +02:00
topecongiro
e59ceaf954
Do not duplicate attributes on use items
2018-05-06 17:01:14 +09:00
topecongiro
f81b94c7c1
Add a test for duplicated attributes on use items
2018-05-06 17:00:51 +09:00
Florian Diebold
215baae223
Add a test for non-mod.rs mods
2018-05-06 09:58:03 +02:00
Florian Diebold
cf573e8157
Fix handling of modules in non_modrs_mods style
...
We need to keep track of the module relative to which we're resolving paths,
instead of always passing None.
Fixes #2673 .
2018-05-06 09:58:03 +02:00
topecongiro
51c07f4335
Fix up lines exceeding max width
2018-05-06 16:17:09 +09:00
topecongiro
5f05987211
Use rustfmt.toml when running self_tests
2018-05-06 16:16:58 +09:00
topecongiro
d560049ae9
Add rustfmt.toml
2018-05-06 16:16:16 +09:00
topecongiro
1f738ea208
Cargo fmt
2018-05-06 15:22:29 +09:00
topecongiro
f8439ce8fe
Put operands on its own line when each fits in a single line
2018-05-06 15:22:17 +09:00
topecongiro
84e5634a1b
Update tests
2018-05-06 15:14:47 +09:00
topecongiro
087e2a7986
Add tests for simple binary expressions
2018-05-06 15:14:30 +09:00
Nick Cameron
3762d80d68
Merge pull request #2678 from topecongiro/issue-2676
...
Do not overflow a long item
2018-05-06 16:18:02 +12:00
topecongiro
f885039e6c
Do not overflow a long item
...
Take the first line's width of a single item into account when
trying to overflow something.
Closes #2676 .
2018-05-06 12:12:16 +09:00
Nick Cameron
17b04f181d
Merge pull request #2677 from csmoe/remove_nested_parens_opt
...
Add remove nested parens option
2018-05-06 14:01:17 +12:00
csmoe
5b121582e5
add config test
2018-05-06 09:23:45 +08:00
Nick Cameron
0cc4a8d848
Update rustc_ap_syntax
2018-05-06 09:57:26 +12:00
Nick Cameron
0f8029f251
Use a different env var for the test directory
2018-05-06 08:23:26 +12:00
csmoe
7c246344f8
remove nested parens option
2018-05-05 23:13:49 +08:00