]> git.lizzy.rs Git - rust.git/log
rust.git
7 years agoAdd two new whitespace options (#1109)
Nathan Ridge [Wed, 3 Aug 2016 01:07:56 +0000 (21:07 -0400)]
Add two new whitespace options (#1109)

* An option to leave a space before the colon in a type annotation

* An option to leave a space before the colon in a trait or lifetime bound

7 years agoMerge pull request #1052 from julienXX/fix-imports-with-absolute-paths
Nick Cameron [Mon, 1 Aug 2016 21:25:25 +0000 (09:25 +1200)]
Merge pull request #1052 from julienXX/fix-imports-with-absolute-paths

Fix imports with absolute paths

7 years agoFix imports with absolute paths
Julien Blanchard [Wed, 8 Jun 2016 11:00:11 +0000 (13:00 +0200)]
Fix imports with absolute paths

7 years agoFix overlong function signature (#1089)
dawirstejeck [Mon, 1 Aug 2016 04:25:00 +0000 (06:25 +0200)]
Fix overlong function signature (#1089)

* Fix issue-1049

* Add testcase suggested by pepyakin

* Fix last commit

* Handle special case

* Remove debugging println

* Fix grammar in comment

* Change word in comment

* Add test for long func without ret type

* Add one more test

7 years agoMultiple config file names feature (#1101)
Daniel Campoverde [Sun, 31 Jul 2016 21:32:35 +0000 (16:32 -0500)]
Multiple config file names feature (#1101)

* Add multiple configuration file names feature

* Add '.rustfmt.toml' in README file

* Clean up configuration file code

* Make config file names constant

* Use only one blank line

7 years agoFix overlong impl (#1091)
dawirstejeck [Tue, 26 Jul 2016 05:34:11 +0000 (07:34 +0200)]
Fix overlong impl (#1091)

* Fix issue-1048

* Take possible where-clause into account

* Move test to existing test set

* Fix wrong variable name

7 years agoAdd `use` declaration re-ordering (#1104)
Stuart Dootson [Tue, 26 Jul 2016 05:20:01 +0000 (06:20 +0100)]
Add `use` declaration re-ordering (#1104)

* Add config options for combinations of lines and items

* Reordering of import lines implemented.

* Changed nested matches to tuple pattern matching

* Added ordering of path list items to the ordering of use declarations

* Move `format_imports` and `format_import` methods to `imports.rs`

* Add comment to explain how `use` declarations are split off while walking through a module

* Change `ImportReordering` config option to separate boolean options

7 years agoCanonicalize file paths within the map of file line ranges (#1098)
Stuart Dootson [Mon, 18 Jul 2016 21:05:01 +0000 (22:05 +0100)]
Canonicalize file paths within the map of file line ranges (#1098)

* Canonicalize file paths within the map of file line ranges

* Forgot to run the tests - and of course, the formatting of the canonicalization change was off, but it's fixed now!

* Move imports to the top of the file, as per @nrc.

* Change `canonicalize_path_string` to return `Option<String>`, `None` indicating an error rather than an empty string

* `format!` is better than string concatenation...

* Change `canonicalize_path_string` to return `Result` rather than `Option`

7 years agoMerge pull request #1100 from studoot/add-appveyor-support
Nick Cameron [Sun, 17 Jul 2016 20:04:23 +0000 (08:04 +1200)]
Merge pull request #1100 from studoot/add-appveyor-support

Add Appveyor CI support

7 years agoAdd appveyor CI support
Stuart Dootson [Fri, 15 Jul 2016 09:37:23 +0000 (10:37 +0100)]
Add appveyor CI support

8 years agoMerge pull request #1088 from sinkuu/issue_1086
Nick Cameron [Sun, 10 Jul 2016 22:24:53 +0000 (10:24 +1200)]
Merge pull request #1088 from sinkuu/issue_1086

Fix formatting empty block comments (`/**/`)

8 years agoFix formatting empty block comments (`/**/`)
sinkuu [Sat, 9 Jul 2016 13:41:28 +0000 (22:41 +0900)]
Fix formatting empty block comments (`/**/`)

issue #1086

8 years agoMerge pull request #1084 from johannhof/rustfmt-not-found
Nick Cameron [Mon, 4 Jul 2016 09:30:52 +0000 (21:30 +1200)]
Merge pull request #1084 from johannhof/rustfmt-not-found

Show more helpful error if rustfmt is not in PATH.

8 years agoShow more helpful error if rustfmt is not in PATH.
Johann Hofmann [Sat, 2 Jul 2016 20:19:04 +0000 (22:19 +0200)]
Show more helpful error if rustfmt is not in PATH.

This fixes #1071.

8 years agoMerge pull request #1083 from KaivoAnastetiks/fix/easy-issue-repo
Nick Cameron [Mon, 4 Jul 2016 03:57:00 +0000 (15:57 +1200)]
Merge pull request #1083 from KaivoAnastetiks/fix/easy-issue-repo

Links to the rust-lang-nursery/rustfmt issue list.

8 years agorustup
Nick Cameron [Mon, 4 Jul 2016 03:46:58 +0000 (15:46 +1200)]
rustup

8 years agoLinks to the rust-lang-nursery/rustfmt issue list.
Kaivo Anastetiks [Sat, 2 Jul 2016 15:34:48 +0000 (11:34 -0400)]
Links to the rust-lang-nursery/rustfmt issue list.

8 years agoMerge pull request #1075 from johannhof/diff-exit
Nick Cameron [Wed, 22 Jun 2016 22:24:19 +0000 (10:24 +1200)]
Merge pull request #1075 from johannhof/diff-exit

Return failure exit code on found diffs (fix #906)

8 years agoReturn failure exit code on found diffs (fix #906)
Johann Hofmann [Mon, 20 Jun 2016 18:42:29 +0000 (20:42 +0200)]
Return failure exit code on found diffs (fix #906)

This changes rustfmt to return exit code 4
when run with write mode diff and differences between
the formatted code and the original code are found.

Useful for CI to make sure your contributors actually ran rustfmt.

8 years agoMerge pull request #1064 from dato/patch-2
Nick Cameron [Thu, 16 Jun 2016 08:35:00 +0000 (10:35 +0200)]
Merge pull request #1064 from dato/patch-2

Fix typo in path: ~/cargo/bin → ~/.cargo/bin

8 years agoFix typo in path: ~/cargo/bin → ~/.cargo/bin
Dato Simó [Wed, 15 Jun 2016 03:48:58 +0000 (00:48 -0300)]
Fix typo in path: ~/cargo/bin → ~/.cargo/bin

8 years agoMerge pull request #1054 from sanxiyn/loop-width
Nick Cameron [Tue, 14 Jun 2016 06:32:02 +0000 (08:32 +0200)]
Merge pull request #1054 from sanxiyn/loop-width

Fix width computation in Loop::rewrite

8 years agoFix width computation in Loop::rewrite
Seo Sanghyeon [Wed, 8 Jun 2016 15:43:08 +0000 (00:43 +0900)]
Fix width computation in Loop::rewrite

8 years agoInclude git commit and worktree status in version output (#1060)
Kamal Marhubi [Sun, 12 Jun 2016 08:38:03 +0000 (10:38 +0200)]
Include git commit and worktree status in version output (#1060)

This will help in debugging issues as rustfmt gets more users.

If the working tree is clean, output looks like

    $ target/debug/rustfmt -V
    0.5.0 (9f5ed3b)

If the working tree is dirty, output looks like

    $ target/debug/rustfmt -V
    0.5.0 (9f5ed3b worktree dirty)

If git is unavailable, output looks like

    $ target/debug/rustfmt -V
    0.5.0 (git commit unavailable)

To avoid rebuilds on changing tests, the build script will only rerun if
files under src/ are changed. This means the actual git status may show
changed files and this would not show up in the version. This should not
be an issue as files not in src/ should not affect the build output.

8 years agoMerge pull request #1061 from marcusklaas/fix-subtract2
Nick Cameron [Fri, 10 Jun 2016 15:23:40 +0000 (17:23 +0200)]
Merge pull request #1061 from marcusklaas/fix-subtract2

Fix integer underflow in extra_offset

8 years agoFix integer underflow in extra_offset
Marcus Klaas [Fri, 10 Jun 2016 14:16:14 +0000 (16:16 +0200)]
Fix integer underflow in extra_offset

8 years agoMerge pull request #1059 from marcusklaas/fix-subtract
Nick Cameron [Fri, 10 Jun 2016 14:00:46 +0000 (16:00 +0200)]
Merge pull request #1059 from marcusklaas/fix-subtract

Fix integer underflow

8 years agoFix integer underflow
Marcus Klaas [Fri, 10 Jun 2016 13:09:27 +0000 (15:09 +0200)]
Fix integer underflow

8 years agoMerge pull request #1042 from imjacobclark/1014-refactoring-vector-string-to-join
Marcus Klaas de Vries [Tue, 7 Jun 2016 18:21:54 +0000 (20:21 +0200)]
Merge pull request #1042 from imjacobclark/1014-refactoring-vector-string-to-join

Refactor string collects to itertools join

8 years agoRefactoring exsisting filter_maps to maps
Jacob Clark [Mon, 6 Jun 2016 23:03:25 +0000 (00:03 +0100)]
Refactoring exsisting filter_maps to maps

8 years agoRefactor string collects to itertools join
Jacob Clark [Mon, 6 Jun 2016 21:30:40 +0000 (22:30 +0100)]
Refactor string collects to itertools join

8 years agoMerge pull request #1033 from marcusklaas/assignment-break
Nick Cameron [Sun, 5 Jun 2016 17:06:08 +0000 (18:06 +0100)]
Merge pull request #1033 from marcusklaas/assignment-break

Add test for general assignment breaks

8 years agoMerge pull request #1032 from marcusklaas/else-if-let-overflow
Nick Cameron [Sun, 5 Jun 2016 17:05:19 +0000 (18:05 +0100)]
Merge pull request #1032 from marcusklaas/else-if-let-overflow

Fix constraints on pattern formatting of else arms

8 years agoAdd test for general assignment breaks
Marcus Klaas [Sat, 4 Jun 2016 09:00:01 +0000 (11:00 +0200)]
Add test for general assignment breaks

8 years agoFix constraints on pattern formatting of else arms
Marcus Klaas [Fri, 3 Jun 2016 21:18:19 +0000 (23:18 +0200)]
Fix constraints on pattern formatting of else arms

8 years agoMerge pull request #1030 from nokaa/master
Nick Cameron [Fri, 3 Jun 2016 09:06:56 +0000 (10:06 +0100)]
Merge pull request #1030 from nokaa/master

Update Vim integration instructions

8 years agoUpdate Vim integration instructions
nokaa [Fri, 3 Jun 2016 07:52:48 +0000 (02:52 -0500)]
Update Vim integration instructions

8 years agoMerge pull request #1016 from rust-lang-nursery/try-double-indent
Nick Cameron [Wed, 1 Jun 2016 11:28:36 +0000 (12:28 +0100)]
Merge pull request #1016 from rust-lang-nursery/try-double-indent

Treat chains with just expr? specially.

8 years agoAdd support for the `default` keyword (#1025)
lqd [Tue, 31 May 2016 17:48:49 +0000 (19:48 +0200)]
Add support for the `default` keyword (#1025)

Adds support for Defaultness on impl methods.
Fixes #945

8 years agoMerge pull request #1023 from kamalmarhubi/diff-color-fix
Nick Cameron [Tue, 31 May 2016 14:27:11 +0000 (15:27 +0100)]
Merge pull request #1023 from kamalmarhubi/diff-color-fix

print_diff: Don't print color codes if output is not a tty

8 years agoprint_diff: Don't print color codes if output is not a tty
Kamal Marhubi [Tue, 31 May 2016 13:15:33 +0000 (15:15 +0200)]
print_diff: Don't print color codes if output is not a tty

On unix, `term::stdout()` just reads the `TERM` environment variable to
decide what features are available. It does not check if the output file
descriptor is in fact a tty. This resulted in printing escape codes when
redirecting output.

8 years agoMerge pull request #1007 from kamalmarhubi/basic-line-ranges-v2
Nick Cameron [Tue, 31 May 2016 07:45:45 +0000 (08:45 +0100)]
Merge pull request #1007 from kamalmarhubi/basic-line-ranges-v2

Add infrastructure for formatting specific line ranges

8 years agoREADME: Explain that --file-lines ranges are 1-based
Kamal Marhubi [Mon, 30 May 2016 22:42:14 +0000 (00:42 +0200)]
README: Explain that --file-lines ranges are 1-based

8 years agoExplain that FileLines cannot be given in rustfmt.toml
Kamal Marhubi [Mon, 30 May 2016 14:41:43 +0000 (16:41 +0200)]
Explain that FileLines cannot be given in rustfmt.toml

This adds a note to both the `--config-help` output for `file_lines`,
and to the panic message on attempting to deserialize a `FileLines`
struct.

8 years agocodemap: Add module description
Kamal Marhubi [Mon, 30 May 2016 14:10:26 +0000 (16:10 +0200)]
codemap: Add module description

8 years agoAdd copyright notices to added files
Kamal Marhubi [Mon, 30 May 2016 14:10:12 +0000 (16:10 +0200)]
Add copyright notices to added files

8 years agorustfmt: Add option to specify line ranges for formatting
Kamal Marhubi [Sun, 10 Apr 2016 17:03:54 +0000 (13:03 -0400)]
rustfmt: Add option to specify line ranges for formatting

This commit adds the `--experimental-file-lines` option to rustfmt. This
allows specifying line ranges to format from the command line.

Refs #434

8 years agovisitor: Handle specified line ranges in visit_stmt
Kamal Marhubi [Sat, 12 Mar 2016 00:19:16 +0000 (19:19 -0500)]
visitor: Handle specified line ranges in visit_stmt

This commit adds a very rough implementation of handling the specified
line ranges in `config.file_lines_map` for statements. It reformats a
statement if its span is fully contained in the set of lines specified
for the file.

The implementation here is intended as a proof of concept, and
demonstration that the machinery added in the preceding commits is
functional. A final implementation would likely hook in via the
`Rewrite` trait.

Refs #434

8 years agoAdd type to represent collection of lines in files
Kamal Marhubi [Thu, 26 May 2016 12:17:20 +0000 (14:17 +0200)]
Add type to represent collection of lines in files

This commit adds a type to represent lines in files, and adds it to the
`Config` struct. It will be used for restricting formatting to specific
lines.

Refs #434

8 years agocodemap: Add utilities for looking up line ranges of spans
Kamal Marhubi [Thu, 26 May 2016 11:49:19 +0000 (13:49 +0200)]
codemap: Add utilities for looking up line ranges of spans

This commit adds extension methods to `Codemap` to allow looking up line
ranges for spans.

Refs #434

8 years agoutils: Move codemap related utilities to a dedicated module
Kamal Marhubi [Wed, 25 May 2016 18:41:26 +0000 (20:41 +0200)]
utils: Move codemap related utilities to a dedicated module

This commit adds a `codemap` module, and moves the `CodemapSpanUtils`
added in #857 to it. This is preparation for adding more `Codemap`
specific utilities.

Refs #434

8 years agovisitor: Add debug log for FmtVisitor::visit_stmt()
Kamal Marhubi [Wed, 25 May 2016 18:41:26 +0000 (20:41 +0200)]
visitor: Add debug log for FmtVisitor::visit_stmt()

8 years agoDerive Debug for the Input enum
Kamal Marhubi [Wed, 25 May 2016 18:41:26 +0000 (20:41 +0200)]
Derive Debug for the Input enum

8 years agoMerge pull request #1017 from marcusklaas/tweak-if-else
Nick Cameron [Mon, 30 May 2016 13:57:29 +0000 (01:57 +1200)]
Merge pull request #1017 from marcusklaas/tweak-if-else

Format non-statement if-else expressions on a single line

8 years agoMerge pull request #1022 from kamalmarhubi/update-syntex-syntax
Nick Cameron [Mon, 30 May 2016 13:25:09 +0000 (01:25 +1200)]
Merge pull request #1022 from kamalmarhubi/update-syntex-syntax

deps: Update syntex_syntax to 0.33

8 years agoMerge pull request #1015 from srinivasreddy/readme
Nick Cameron [Mon, 30 May 2016 13:24:07 +0000 (01:24 +1200)]
Merge pull request #1015 from srinivasreddy/readme

Add section - Installing from source

8 years agodeps: Update syntex_syntax to 0.33
Kamal Marhubi [Mon, 30 May 2016 12:53:04 +0000 (14:53 +0200)]
deps: Update syntex_syntax to 0.33

This bump brings syntex_syntax support for `..` in tuple and tuple
struct patterns, which come from RFC 1492:
  https://github.com/rust-lang/rfcs/blob/master/text/1492-dotdot-in-patterns.md

These new patterns are not properly handled in this PR; instead #1021
tracks supporting them.

Refs #1021

8 years agoFormat non-statement if-else expressions on a single line
Marcus Klaas [Sun, 29 May 2016 15:58:38 +0000 (17:58 +0200)]
Format non-statement if-else expressions on a single line

8 years agoTreat chains with just expr? specially.
Nick Cameron [Sat, 28 May 2016 20:50:25 +0000 (21:50 +0100)]
Treat chains with just expr? specially.

Fixes #1004

8 years agoAdd section - Installing from source
Srinivas Reddy Thatiparthy [Sat, 28 May 2016 15:38:33 +0000 (21:08 +0530)]
Add section - Installing from source

8 years agoHandle pub(restricted) (#1013)
Kamal Marhubi [Fri, 27 May 2016 22:58:25 +0000 (00:58 +0200)]
Handle pub(restricted) (#1013)

* Handle pub(restricted)

This commit properly handles pub(restricted) as introduced in RFC 1422
[0]. The syntax support was added in #971, but they were not correctly
formatted.

[0] https://github.com/rust-lang/rfcs/blob/master/text/1422-pub-restricted.md

Fixes #970

* Drop #[inline] attribute on format_visibility

* Make newly non-failing functions return String

The change to `format_visibiilty` means that `format_header` and
`format_unit_struct` can no longer fail. Their return type is updated to
reflect that.

8 years agoMerge pull request #1008 from rust-lang-nursery/hrtb
Nick Cameron [Fri, 27 May 2016 22:08:00 +0000 (10:08 +1200)]
Merge pull request #1008 from rust-lang-nursery/hrtb

Don't ignore universal quantification in function types

8 years agoDon't ignore universal quantification in function types
Nick Cameron [Thu, 26 May 2016 22:39:28 +0000 (10:39 +1200)]
Don't ignore universal quantification in function types

Fixes #1006

8 years agoMerge pull request #1009 from rust-lang-nursery/fn-args-1
Nick Cameron [Fri, 27 May 2016 22:04:04 +0000 (10:04 +1200)]
Merge pull request #1009 from rust-lang-nursery/fn-args-1

Fix off by 2 error in function sigs

8 years agoFix off by 2 error in function sigs
Nick Cameron [Thu, 26 May 2016 23:49:26 +0000 (11:49 +1200)]
Fix off by 2 error in function sigs

Fixes #1000

This is a little conservative in some cases, but better than being wrong in others.

8 years agoDon't put a newline before `?` when it is the second sub-expression in a chain (...
Nick Cameron [Fri, 27 May 2016 08:33:19 +0000 (20:33 +1200)]
Don't put a newline before `?` when it is the second sub-expression in a chain (#1012)

Fixes #1003

8 years agoOptionally put short struct variants on one line (#997)
Nick Cameron [Wed, 18 May 2016 20:38:49 +0000 (08:38 +1200)]
Optionally put short struct variants on one line (#997)

Closes #418

8 years agoFormat inline attributes on out-of-line modules (#996)
Nick Cameron [Wed, 18 May 2016 20:36:59 +0000 (08:36 +1200)]
Format inline attributes on out-of-line modules (#996)

Fixes #838

8 years agoMerge branch 'master' of github.com:rust-lang-nursery/rustfmt
Nick Cameron [Tue, 17 May 2016 22:02:04 +0000 (10:02 +1200)]
Merge branch 'master' of github.com:rust-lang-nursery/rustfmt

8 years agoHandle parser errors better
Nick Cameron [Tue, 17 May 2016 21:58:51 +0000 (09:58 +1200)]
Handle parser errors better

8 years agoFall back to basic stdout if we can't unwrap a fancy terminal (#995)
Nick Cameron [Tue, 17 May 2016 21:25:57 +0000 (09:25 +1200)]
Fall back to basic stdout if we can't unwrap a fancy terminal (#995)

fixes #978

8 years agoMerge pull request #992 from srinivasreddy/master
Nick Cameron [Sun, 15 May 2016 22:15:29 +0000 (10:15 +1200)]
Merge pull request #992 from srinivasreddy/master

change  normalise spelling to American version -

8 years agoNote in te README about compiler version
Nick Cameron [Sun, 15 May 2016 22:09:53 +0000 (10:09 +1200)]
Note in te README about compiler version

Closes #990

8 years agochange normalise spelling to American version - normalize as American english is...
Srinivas Reddy Thatiparthy [Sun, 15 May 2016 16:49:44 +0000 (22:19 +0530)]
change  normalise spelling to American version - normalize as American english is more common across programming community

8 years agoWrite each file as it is formatted (#991)
Nick Cameron [Sun, 15 May 2016 09:41:05 +0000 (21:41 +1200)]
Write each file as it is formatted (#991)

The old behaviour stored everything in memory until we were finished. Now we write as soon as we can.

This gives better behaviour when formatting large programs, since there is some progress indication. It also opens the door to optimising memory use by not storing everything in memory unless it is required (which it still might be). That is left as future work though.

8 years ago0.5 release
Nick Cameron [Fri, 13 May 2016 19:34:55 +0000 (12:34 -0700)]
0.5 release

8 years agoMerge pull request #893 from marcusklaas/try-shorthand
Nick Cameron [Thu, 12 May 2016 23:07:42 +0000 (16:07 -0700)]
Merge pull request #893 from marcusklaas/try-shorthand

Try shorthand

8 years agoBootstrap it. Hard.
Marcus Klaas [Thu, 12 May 2016 19:50:43 +0000 (21:50 +0200)]
Bootstrap it. Hard.

8 years agoAdd try macro to try shorthand conversion tests
Marcus Klaas [Mon, 9 May 2016 18:11:25 +0000 (20:11 +0200)]
Add try macro to try shorthand conversion tests

8 years agoFormat try shorthand
Marcus Klaas [Mon, 9 May 2016 18:07:59 +0000 (20:07 +0200)]
Format try shorthand

8 years agoMerge pull request #981 from DanielJCampbell/generated
Nick Cameron [Fri, 6 May 2016 02:02:56 +0000 (14:02 +1200)]
Merge pull request #981 from DanielJCampbell/generated

Altered FmtVisitor to function correctly on generated code

8 years agoAltered FmtVisitor to function correctly on generated code
Daniel Campbell [Fri, 6 May 2016 01:02:42 +0000 (13:02 +1200)]
Altered FmtVisitor to function correctly on generated code

8 years agoMerge pull request #980 from DanielJCampbell/visibility
Nick Cameron [Fri, 6 May 2016 01:09:46 +0000 (13:09 +1200)]
Merge pull request #980 from DanielJCampbell/visibility

Changed modules & visitor mods to public, set filemap::write_file public

8 years agoChanged modules & visitor mods to public, set filemap::write_file public
Daniel Campbell [Fri, 6 May 2016 00:20:38 +0000 (12:20 +1200)]
Changed modules & visitor mods to public, set filemap::write_file public

8 years agoMerge pull request #979 from kamalmarhubi/update-syntex-syntax
Nick Cameron [Thu, 5 May 2016 20:59:02 +0000 (08:59 +1200)]
Merge pull request #979 from kamalmarhubi/update-syntex-syntax

deps: Update syntex_syntax to 0.32.0

8 years agodeps: Update syntex_syntax to 0.32.0
Kamal Marhubi [Mon, 2 May 2016 03:01:46 +0000 (23:01 -0400)]
deps: Update syntex_syntax to 0.32.0

8 years agoMerge pull request #974 from sanxiyn/unused-trait-import
Nick Cameron [Tue, 3 May 2016 20:32:26 +0000 (08:32 +1200)]
Merge pull request #974 from sanxiyn/unused-trait-import

Remove unused trait imports

8 years agoRemove unused trait imports
Seo Sanghyeon [Tue, 3 May 2016 12:52:55 +0000 (21:52 +0900)]
Remove unused trait imports

8 years agoMerge pull request #973 from habnabit/fix-associated-items
Nick Cameron [Tue, 3 May 2016 05:22:50 +0000 (17:22 +1200)]
Merge pull request #973 from habnabit/fix-associated-items

Don't misplace the :: on associated items.

8 years agoDon't misplace the :: on associated items.
Aaron Gallagher [Tue, 3 May 2016 00:11:22 +0000 (17:11 -0700)]
Don't misplace the :: on associated items.

The rewritten location of the :: on global paths for qpaths was wrong.

8 years agoMerge pull request #971 from kamalmarhubi/update-syntex-syntax
Nick Cameron [Mon, 2 May 2016 21:19:50 +0000 (09:19 +1200)]
Merge pull request #971 from kamalmarhubi/update-syntex-syntax

deps: Update syntex_syntax to 0.31.0

8 years agoHandle attributes on modules (#968)
Nick Cameron [Mon, 2 May 2016 08:54:25 +0000 (20:54 +1200)]
Handle attributes on modules (#968)

* Handle attributes (including doc comments) on inline modules

Closes #22
Closes #684

* Tweak the rules for changing indentation in comments (to do it less often).

8 years agoHandle new visibility types more gracefully
Kamal Marhubi [Mon, 2 May 2016 05:05:23 +0000 (01:05 -0400)]
Handle new visibility types more gracefully

8 years agodeps: Update syntex_syntax to 0.31.0
Kamal Marhubi [Mon, 2 May 2016 03:01:46 +0000 (23:01 -0400)]
deps: Update syntex_syntax to 0.31.0

Most of the churn on this bump comes from the `Visibility` enum changing
from

    pub enum Visibility {
        Public,
        Inherited,
    }

to

    pub enum Visibility {
        Public,
        Crate,
        Restricted { path: P<Path>, id: NodeId },
        Inherited,
    }

which require taking `Visibility` by reference in most places. The new
variants are not handled at this point.

Refs #970

8 years agoMerge pull request #966 from MicahChalmer/skip-children-in-plain-write-mode
Nick Cameron [Thu, 28 Apr 2016 06:15:22 +0000 (18:15 +1200)]
Merge pull request #966 from MicahChalmer/skip-children-in-plain-write-mode

Always skip children when using Plain write mode

8 years agoAlways skip children when using Plain write mode
Micah Chalmer [Thu, 28 Apr 2016 05:38:04 +0000 (01:38 -0400)]
Always skip children when using Plain write mode

Outputting child module contents in the "Plain" write mode does not make
sense, since there is no way to differentiate code that came from a
child module from that which came from the parent file.

8 years agoMerge pull request #960 from rust-lang-nursery/big-closures
Nick Cameron [Wed, 27 Apr 2016 21:49:08 +0000 (09:49 +1200)]
Merge pull request #960 from rust-lang-nursery/big-closures

Block indent large closures and field/method chains

8 years agoAdd visual indent tests for chains
Nick Cameron [Wed, 27 Apr 2016 20:08:54 +0000 (08:08 +1200)]
Add visual indent tests for chains

8 years agoBail out on recovered errors. (#965)
Nick Cameron [Wed, 27 Apr 2016 19:08:44 +0000 (07:08 +1200)]
Bail out on recovered errors. (#965)

Closes #915
Closes #930
Closes #931

8 years agoFix for stable
Nick Cameron [Tue, 26 Apr 2016 02:27:13 +0000 (14:27 +1200)]
Fix for stable