Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(13)

Side by Side Diff: test/splitting/constructors.unit

Issue 889943004: Indent the parameter list more if the body is a wrapped "=>". Fix #144. (Closed) Base URL: https://github.com/dart-lang/dart_style.git@master
Patch Set: Update changelog. Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « test/regression/144.unit ('k') | test/splitting/parameters.unit » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 40 columns | 1 40 columns |
2 >>> Single initializers can be on one line 2 >>> Single initializers can be on one line
3 class Foo extends Bar { 3 class Foo extends Bar {
4 final int b; 4 final int b;
5 Foo(int a, this.b) : super(a); 5 Foo(int a, this.b) : super(a);
6 } 6 }
7 <<< 7 <<<
8 class Foo extends Bar { 8 class Foo extends Bar {
9 final int b; 9 final int b;
10 Foo(int a, this.b) : super(a); 10 Foo(int a, this.b) : super(a);
(...skipping 29 matching lines...) Expand all
40 new Thing(argument, argument); 40 new Thing(argument, argument);
41 >>> splits before ":" if the parameter list does not fit on one line 41 >>> splits before ":" if the parameter list does not fit on one line
42 class Foo { 42 class Foo {
43 Foo(int longArg1, int longArg2, int longArg3) : this._(longArg1); 43 Foo(int longArg1, int longArg2, int longArg3) : this._(longArg1);
44 } 44 }
45 <<< 45 <<<
46 class Foo { 46 class Foo {
47 Foo(int longArg1, int longArg2, 47 Foo(int longArg1, int longArg2,
48 int longArg3) 48 int longArg3)
49 : this._(longArg1); 49 : this._(longArg1);
50 } 50 }
51 >>> indent parameters more if body is a wrapped =>
52 class Foo {
53 Foo(firstArgument, secondArgument, third) => "very long body that must wrap";
54 }
55 <<<
56 class Foo {
57 Foo(firstArgument, secondArgument,
58 third) =>
59 "very long body that must wrap";
60 }
OLDNEW
« no previous file with comments | « test/regression/144.unit ('k') | test/splitting/parameters.unit » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698