Nick Cameron
b46c147fed
0.8.3
...
Because I forgot to merge a PR into 0.8.2 that I really wanted :-(
2017-04-06 21:29:26 +12:00
Nick Cameron
bdcb8d663e
Merge pull request #1438 from topecongiro/poor-formatting/method-chains
...
Lookup the last element of 'subexpr_list' instead of the first one
2017-04-06 21:26:13 +12:00
Nick Cameron
fa732ede8b
v0.8.2
2017-04-06 21:22:29 +12:00
Nick Cameron
ee9daade35
Fix a bug with overlong function calls
2017-04-06 21:17:22 +12:00
Nick Cameron
a7183766b9
Test fallout
2017-04-06 13:06:11 +12:00
Nick Cameron
f4952d3780
Implement a max array width
...
Fixes #1421
2017-04-06 13:01:19 +12:00
topecongiro
8d22e85e48
Lookup the last element of 'subexpr_list' instead of the first one
...
Closes #1217 , #1236 , #1389 and #1434 .
2017-04-06 09:26:25 +09:00
Nick Cameron
b3a4ba570e
Merge pull request #1432 from topecongiro/parse-config
...
Print error and usage when decoding config file failed
2017-04-06 11:30:33 +12:00
Nick Cameron
d476bef7ed
Merge pull request #1436 from Ryan1729/master
...
fix for #1419 and #1425
2017-04-05 08:32:21 +12:00
Ryan1729
eb25ac5e11
eliminate nested match
2017-04-04 00:01:33 -06:00
Ryan1729
4c4f70957b
fix bug by adding boolean argument
...
Signed-off-by: Ryan1729 <Ryan1729@gmail.com>
2017-04-03 17:39:14 -06:00
Ryan1729
822b266a3d
add tests that fail because of comma insertion
...
Signed-off-by: Ryan1729 <Ryan1729@gmail.com>
2017-04-03 16:15:11 -06:00
topecongiro
6af0968511
Change return type of 'from_toml' from 'Config' to 'Result<Config>'
...
Closes #1426 .
2017-04-03 13:58:46 +09:00
Nick Cameron
f63815ee95
Merge pull request #1435 from iliekturtles/line-length
...
Do not count `\r` as part of line width.
2017-04-03 08:40:22 +12:00
Nick Cameron
20395c5c55
Merge pull request #1430 from fintelia/stdin_lines
...
The --file_lines argument now supports "stdin"
2017-04-03 08:27:35 +12:00
Nick Cameron
e94a97d9a1
Merge pull request #1431 from topecongiro/fix-1428
...
Check existence of pre comment explicitly
2017-04-03 07:53:18 +12:00
Mike Boutin
a0efdf2de9
Do not count \r
as part of line width.
...
Resolves #1335 . Does not attempt to handle a `\r` not followed by a `\n` nor
attempt to handle Unicode intricacies (#6 ) including zero-width or multi-byte
characters.
2017-04-02 11:09:29 -04:00
Jonathan Behrens
6241469a69
Warn about extra files listed in file_lines argument
2017-03-31 13:34:53 -04:00
topecongiro
34b90d8716
Check existence of pre comment explicitly
...
This commit fixes #1428 .
2017-03-31 21:57:29 +09:00
Jonathan Behrens
56da223dc2
--file_lines argument now supports "stdin"
2017-03-30 19:35:58 -04:00
Nick Cameron
3edc184221
Merge pull request #1413 from Emilgardis/master
...
Implemented support for workspaces
2017-03-31 08:43:40 +13:00
Nick Cameron
4f226eb909
Merge pull request #1424 from topecongiro/long-struct
...
Split long fields in structs
2017-03-31 08:42:40 +13:00
topecongiro
3a1ffa7db7
Split long fields in structs
...
This commit splits long fields in structs.
Closes #1412 .
2017-03-30 13:37:34 +09:00
Nick Cameron
6c206d2931
Skip doctests
2017-03-30 15:49:10 +13:00
Nick Cameron
5fb2fc910b
Merge pull request #1423 from fintelia/master
...
Format any statement whose span intersects file_lines
2017-03-30 15:33:36 +13:00
Emil Gardström
6971b4b5c9
Implemented support for workspaces
...
closes rust-lang-nursery/rustfmt#1244
2017-03-30 03:29:32 +02:00
Jonathan Behrens
36f0402bac
Canonicalize range path in FileLines::intersects()
2017-03-29 18:50:39 -04:00
Jonathan Behrens
b6f1b516d9
Format any statement whose span intersects file_lines
2017-03-29 01:33:14 -04:00
Nick Cameron
603f26d8f1
Merge pull request #1415 from topecongiro/remove-duplicates
...
Remove duplicates
2017-03-29 17:51:19 +13:00
topecongiro
78826e6783
Fix a typo
2017-03-29 09:17:58 +09:00
Nick Cameron
3d2e52a214
Merge pull request #1416 from fanzier/master
...
Omit space before '\n' + comment (fixes #457 )
2017-03-29 07:55:48 +13:00
Fabian Zaiser
6ecc18c7de
Omit space before '\n' + comment ( fixes #457 )
2017-03-28 16:32:12 +02:00
topecongiro
a2d57e956a
Remove duplicate definitions
...
This commit removes duplicated definitions of `type_annotation_separator` and
`type_bound_colon`.
2017-03-28 23:20:50 +09:00
Nick Cameron
7377dfc38c
release v8.1
2017-03-28 13:19:59 +13:00
Nick Cameron
5305bc8436
test fallout
2017-03-28 11:25:59 +13:00
Nick Cameron
a8692797ae
Use a release build in the bootstrap script
2017-03-28 11:20:11 +13:00
Nick Cameron
5fb1140688
fallout - source reformatting
2017-03-28 11:14:47 +13:00
Nick Cameron
a079b87e7c
Use a char len heuristic rather than item count for chain_one_line_max
2017-03-28 11:12:15 +13:00
Nick Cameron
91bbe0ff8b
Test fallout
2017-03-28 11:01:44 +13:00
Nick Cameron
e4efa22983
Source formatting fallout
2017-03-28 10:58:41 +13:00
Nick Cameron
038436919d
Put the second element of a chain on its own line when block formatting.
2017-03-28 10:56:46 +13:00
Nick Cameron
8bca85c4b6
Support block indent for function calls
...
Uses the `fn_call_style` option.
Fixes #1358
2017-03-28 10:43:46 +13:00
Nick Cameron
f53d5dd90c
Merge pull request #1409 from alobb/1408-empty-tuple-enum-decl
...
Prevent conversion of empty tuples to unit structs
2017-03-27 14:28:41 +13:00
Aaron Lobb
548de69d2d
Prevent conversion of empty tuples to unit structs
...
Fixes #1408
2017-03-26 15:47:48 -07:00
C4K3
abca1deded
Add indent_match_arms option ( #1404 )
...
Makes it optional whether to indent arms in match expressions. Setting this
to false may be desirable for people wishing to avoid double-indents, in
that if the match arm is a block, the block will cause an extra indentation
level, and if it isn't a block but just a single line, it's still easy to
see the logic at a glance.
This style is preferred in certain other languages with switch statements,
e.g. Linux style C and the most common Java style.
2017-03-26 18:32:29 +13:00
Aaron Lobb
0dd0cc1941
Break use
statements into multiple lines ( #1407 )
...
This fixes how line lengths for use statements with multiple
items don't extend beyond the maximum line length.
Fixes #1400
2017-03-26 18:21:43 +13:00
Jon Gjengset
f96e56c3a0
Avoid extra comma in vertical single-field struct patterns ( #1403 )
...
* Add (failing) test for #1397
* Fix for #1397
Specifically, we end up double-adding a trailing comma for single-member
struct patterns that are arranged vertically. One is added by write_list
(since such structs return true for needs_trailing_separator), and
another is added by the if in the old code.
2017-03-26 18:16:45 +13:00
C4K3
6be61bcdd6
Warn on unused config options ( #1402 )
...
This will make it clear if a user has misspelled a config option, or if
an option has been changed/removed.
2017-03-26 18:12:56 +13:00
Nick Cameron
488c0b9546
Test and source fallout
2017-03-22 09:25:26 +13:00
Nick Cameron
4bb31a7231
Block indenting for struct lit patterns
...
Now follows struct_lit_style (and most other struct_lit_ options).
Required a fair bit of refactoring and bug fixes.
Fixes #1311
2017-03-22 09:25:26 +13:00