#
f10a28d7 |
| 05-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Understand functions with decltype return type.
Before: decltype(long_name_forcing_break) f() {}
After: decltype(long_name_forcing_break) f() {}
llvm-svn: 207965
|
#
76f98f80 |
| 05-May-2014 |
Dinesh Dwivedi <dinesh.d@samsung.com> |
Added some heuristics to identify c style casting
Before: void f() { my_int a = (my_int) * b; } void f() { return P ? (my_int) * P : (my_int)0; }
After: void f() { my_int a = (my_int)*b; } void f()
Added some heuristics to identify c style casting
Before: void f() { my_int a = (my_int) * b; } void f() { return P ? (my_int) * P : (my_int)0; }
After: void f() { my_int a = (my_int)*b; } void f() { return P ? (my_int)*P : (my_int)0; }
Differential Revision: http://reviews.llvm.org/D3576
llvm-svn: 207964
show more ...
|
#
0e6c51c8 |
| 05-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Improve understanding of decltype.
Before: SomeFunction([](decltype(x), A * a) {});
After: SomeFunction([](decltype(x), A *a) {});
llvm-svn: 207961
|
#
afe6fb6f |
| 05-May-2014 |
Dinesh Dwivedi <dinesh.d@samsung.com> |
Fix bug in clang-format while merging short function
Before: #ifdef _DEBUG int foo( int i = 0 ) #else int foo( int i = 5 ) #endif { return i; }
After: #ifdef _DEBUG int
Fix bug in clang-format while merging short function
Before: #ifdef _DEBUG int foo( int i = 0 ) #else int foo( int i = 5 ) #endif { return i; }
After: #ifdef _DEBUG int foo( int i = 0 ) #else int foo( int i = 5 ) #endif { return i; }
llvm-svn: 207958
show more ...
|
#
9509f188 |
| 05-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Fix import statements with ColumnLimit: 0
These used to interact badly with AlwaysBreakBeforeMultilineStrings.
llvm-svn: 207955
|
#
ea3aca8b |
| 02-May-2014 |
Dinesh Dwivedi <dinesh.d@samsung.com> |
Fixes issue with Allman BreakBeforeBraces for Objective C @interface
Before: @interface BSApplicationController () { @private id _extraIvar; } @end
After: @interface B
Fixes issue with Allman BreakBeforeBraces for Objective C @interface
Before: @interface BSApplicationController () { @private id _extraIvar; } @end
After: @interface BSApplicationController () { @private id _extraIvar; } @end
llvm-svn: 207849
show more ...
|
#
35995679 |
| 29-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Allow single-line function in WebKit style.
Before: void f() { return; }
After: void f() { return; }
llvm-svn: 207527
|
#
942d971c |
| 28-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Improve binary operator detection.
Before: *(int *)(p &~3UL) = 0;
After: *(int *)(p & ~3UL) = 0;
This fixes llvm.org/PR19464.
llvm-svn: 207405
|
#
031e2409 |
| 28-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Fixes spaces in case statements.
This fixes llvm.org/PR19482.
Before: switch (a) { case(B) : return; }
After: switch (a) { case (B): return; }
llvm-svn:
clang-format: Fixes spaces in case statements.
This fixes llvm.org/PR19482.
Before: switch (a) { case(B) : return; }
After: switch (a) { case (B): return; }
llvm-svn: 207402
show more ...
|
#
437c3f51 |
| 28-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Don't wrap after @interface.
This fixes llvm.org/PR19450.
Before: @interface BookmarkHomeHandsetViewController ()<BookmarkAllCollectionViewDelegate,
clang-format: Don't wrap after @interface.
This fixes llvm.org/PR19450.
Before: @interface BookmarkHomeHandsetViewController ()<BookmarkAllCollectionViewDelegate, BookmarkFolderCollectionViewDelegate, BookmarkMenuViewControllerDelegate, BookmarkSearchViewControllerDelegate> { }
After: @interface aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa ()< aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa, aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa, aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa, aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa> { }
llvm-svn: 207400
show more ...
|
#
66935020 |
| 27-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Fix bug when aligning trailing /**/-comments in macros.
Previously this could lead to a column limit violation with the required escaped newlines.
llvm-svn: 207351
|
Revision tags: llvmorg-3.4.1, llvmorg-3.4.1-rc2 |
|
#
10346667 |
| 22-Apr-2014 |
Chandler Carruth <chandlerc@gmail.com> |
[Modules] Fix potential ODR violations by sinking the DEBUG_TYPE definition below all of the header #include lines, clang edition.
If you want more details about this, you can see some of the commit
[Modules] Fix potential ODR violations by sinking the DEBUG_TYPE definition below all of the header #include lines, clang edition.
If you want more details about this, you can see some of the commits to Debug.h in LLVM recently. This is just the clang section of a cleanup I've done for all uses of DEBUG_TYPE in LLVM.
llvm-svn: 206849
show more ...
|
#
67d9c8c8 |
| 17-Apr-2014 |
Alexander Kornienko <alexfh@google.com> |
Fix alignment of trailing block comments.
Summary: This patch ensures that the lines of the block comments retain relative column offsets. In order to do this WhitespaceManager::Changes representing
Fix alignment of trailing block comments.
Summary: This patch ensures that the lines of the block comments retain relative column offsets. In order to do this WhitespaceManager::Changes representing continuation of block comments keep a pointer on the change representing the whitespace change before the block comment, and a relative column offset to this change, so that the correct column can be reconstructed at the end of alignment process.
Fixes http://llvm.org/PR19325
Reviewers: djasper
Reviewed By: djasper
CC: cfe-commits, klimek
Differential Revision: http://reviews.llvm.org/D3408
llvm-svn: 206472
show more ...
|
#
ae8e0d8d |
| 17-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Respect BinPackParameters in Cpp11BracedListStyle.
With BinPackParameters=false and Cpp11BracedListStyle=true (i.e. mostly for Chromium):
Before: const Aaaaaa aaaaa = {aaaaa, bbbbb,
clang-format: Respect BinPackParameters in Cpp11BracedListStyle.
With BinPackParameters=false and Cpp11BracedListStyle=true (i.e. mostly for Chromium):
Before: const Aaaaaa aaaaa = {aaaaa, bbbbb, ccccc, ddddd, eeeee, ffffff, ggggg, hhhhhh, iiiiii, jjjjjj, kkkkkk};
After: const Aaaaaa aaaaa = {aaaaa, bbbbb, ccccc, ddddd, eeeee, ffffff, ggggg, hhhhhh, iiiiii, jjjjjj, kkkkkk};
This fixes llvm.org/PR19359. I am not sure we'll want this in all cases in the long run, but I'll guess we'll get feedback on that.
llvm-svn: 206458
show more ...
|
#
0e61784a |
| 16-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Add special case to reduce indentaiton in streams.
This is similar to how we treat assignments and seems to be generally desirable.
Before: llvm::errs() << aaaaaaaaaaaaaaaaaaaaaaaaa
clang-format: Add special case to reduce indentaiton in streams.
This is similar to how we treat assignments and seems to be generally desirable.
Before: llvm::errs() << aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( aaaaaaaaaaaaaaaaaaaaaaaaaaaa, aaaaaaaaaaaaaaaaaaaaaaaaaaaa);
After: llvm::errs() << aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa( aaaaaaaaaaaaaaaaaaaaaaaaaaaa, aaaaaaaaaaaaaaaaaaaaaaaaaaaa);
llvm-svn: 206384
show more ...
|
#
64a42b8d |
| 15-Apr-2014 |
Alexander Kornienko <alexfh@google.com> |
Fix assertion when breaking string literals with tab characters.
Summary: Fixes http://llvm.org/PR19368
Reviewers: djasper, klimek
Reviewed By: klimek
CC: cfe-commits, klimek
Differential Revisi
Fix assertion when breaking string literals with tab characters.
Summary: Fixes http://llvm.org/PR19368
Reviewers: djasper, klimek
Reviewed By: klimek
CC: cfe-commits, klimek
Differential Revision: http://reviews.llvm.org/D3379
llvm-svn: 206295
show more ...
|
#
20fd3c6f |
| 15-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Basic support for C++1y.
Before: int bi{1 '000' 000}; After: int bi{1'000'000};
This fixes llvm.org/PR19342.
llvm-svn: 206263
|
#
866468ae |
| 14-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Fix regression caused by r206165.
llvm-svn: 206173
|
#
72ab43b2 |
| 14-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Fix incorrect &&-detection in macros.
Before: #define A(a, b) (a &&b)
After: #define A(a, b) (a && b)
This fixes llvm.org/PR19343.
llvm-svn: 206165
|
#
db8804b3 |
| 14-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Improve array literal formatting fix in r206161.
Instead of choosing based on the number of elements, simply respect the user's choice of where to wrap array literals.
llvm-svn: 206162
|
#
af4fee26 |
| 14-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: With ColumnLimit=0, keep short array literals on a line.
Before: NSArray* a = [[NSArray alloc] initWithArray:@[ @"a"
clang-format: With ColumnLimit=0, keep short array literals on a line.
Before: NSArray* a = [[NSArray alloc] initWithArray:@[ @"a" ] copyItems:YES];
After: NSArray* a = [[NSArray alloc] initWithArray:@[ @"a" ] copyItems:YES];
This fixed llvm.org/PR19080.
llvm-svn: 206161
show more ...
|
#
c0d606a5 |
| 14-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Don't allow hanging indentation for operators on new lines
Before: if (aaaaaaaa && bbbbbbbbbbbbbbb // need to wrap == cccccccccccccc) ...
After: if (aaaaaaaa
clang-format: Don't allow hanging indentation for operators on new lines
Before: if (aaaaaaaa && bbbbbbbbbbbbbbb // need to wrap == cccccccccccccc) ...
After: if (aaaaaaaa && bbbbbbbbbbbbbbb // need to wrap == cccccccccccccc) ...
The same rule has already be implemented for BreakBeforeBinaryOperators set to false in r205527.
llvm-svn: 206159
show more ...
|
#
68b03049 |
| 14-Apr-2014 |
Manuel Klimek <klimek@google.com> |
Format code around VCS conflict markers.
Now correctly formats: { int a; void f() { callme(some(parameter1, <<<<<<< text by the vcs parameter2), ||||||| text by
Format code around VCS conflict markers.
Now correctly formats: { int a; void f() { callme(some(parameter1, <<<<<<< text by the vcs parameter2), ||||||| text by the vcs parameter2), parameter3, ======= text by the vcs parameter2, parameter3), >>>>>>> text by the vcs otherparameter); } }
llvm-svn: 206157
show more ...
|
#
35ec2b24 |
| 14-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Improve formatting of annotated variables.
Before: bool aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa GUARDED_BY( aaaaaaaaaaaa) = aaaaaaaa::aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa;
After:
clang-format: Improve formatting of annotated variables.
Before: bool aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa GUARDED_BY( aaaaaaaaaaaa) = aaaaaaaa::aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa;
After: bool aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa GUARDED_BY(aaaaaaaaaaaa) = aaaaaaaa::aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa;
llvm-svn: 206155
show more ...
|
Revision tags: llvmorg-3.4.1-rc1 |
|
#
f9fc215f |
| 09-Apr-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Treat a trailing comment like a trailing comma in braced lists.
Before: static StructInitInfo module = {MODULE_BUILTIN, /* type */ "streams" /* name
clang-format: Treat a trailing comment like a trailing comma in braced lists.
Before: static StructInitInfo module = {MODULE_BUILTIN, /* type */ "streams" /* name */ };
After: static StructInitInfo module = { MODULE_BUILTIN, /* type */ "streams" /* name */ };
This fixes llvm.org/PR19378.
llvm-svn: 205851
show more ...
|