#
5217a8b8 |
| 13-Jun-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Understand named function literals.
Before: return {a: function SomeFunction(){// ... return 1; } } ;
After: return { a: functi
clang-format: [JS] Understand named function literals.
Before: return {a: function SomeFunction(){// ... return 1; } } ;
After: return { a: function SomeFunction() { // ... return 1; } };
llvm-svn: 210887
show more ...
|
#
17062ff5 |
| 10-Jun-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Treat dict literals similar to objc method exprs.
Before: return { link: function() { f(); // } }; return { a: a, link: function
clang-format: [JS] Treat dict literals similar to objc method exprs.
Before: return { link: function() { f(); // } }; return { a: a, link: function() { f(); // } }
After: return { link: function() { f(); // } }; return { a: a, link: function() { f(); // } };
llvm-svn: 210537
show more ...
|
#
58cb2edd |
| 06-Jun-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Fix incorrect indentation.
Before (JavaScript example, but can extend to other languages): return { a: 'E', b: function() { return function() { f(); // This is w
clang-format: Fix incorrect indentation.
Before (JavaScript example, but can extend to other languages): return { a: 'E', b: function() { return function() { f(); // This is wrong. }; } };
After: return { a: 'E', b: function() { return function() { f(); // This is better. }; } };
llvm-svn: 210334
show more ...
|
#
114a2bc9 |
| 03-Jun-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Refactor indentation behavior for multiple nested blocks.
This fixes a few oddities when formatting multiple nested JavaScript blocks, e.g.:
Before: promise.then( function suc
clang-format: Refactor indentation behavior for multiple nested blocks.
This fixes a few oddities when formatting multiple nested JavaScript blocks, e.g.:
Before: promise.then( function success() { doFoo(); doBar(); }, [], function error() { doFoo(); doBaz(); }); promise.then([], function success() { doFoo(); doBar(); }, function error() { doFoo(); doBaz(); });
After: promise.then( function success() { doFoo(); doBar(); }, [], function error() { doFoo(); doBaz(); }); promise.then([], function success() { doFoo(); doBar(); }, function error() { doFoo(); doBaz(); });
llvm-svn: 210097
show more ...
|
#
49802ef9 |
| 22-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Understand line breaks in concatenated strings.
Before: var literal = 'hello ' + 'world';
After: var literal = 'hello ' + 'world';
There is no reason to conc
clang-format: [JS] Understand line breaks in concatenated strings.
Before: var literal = 'hello ' + 'world';
After: var literal = 'hello ' + 'world';
There is no reason to concatenated two string literals with a '+' unless the line break is intended.
llvm-svn: 209413
show more ...
|
#
5f3ea477 |
| 22-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Correctly calculate line lenghts for nest blocks.
If simple (one-statement) blocks can be inlined, the length needs to be calculated correctly.
Before (in JavaScript but this also aff
clang-format: Correctly calculate line lenghts for nest blocks.
If simple (one-statement) blocks can be inlined, the length needs to be calculated correctly.
Before (in JavaScript but this also affects lambdas, etc.): var x = { valueOf: function() { return 1; } };
After: var x = {valueOf: function() { return 1; }};
llvm-svn: 209410
show more ...
|
#
2a958321 |
| 21-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Fix corner case working around one-per-line dict literals.
Before: var object_literal_with_long_name = { a: 'aaaaaaaaaaaaaaaaaa', b: 'bbbbbbbbbbbbbbbbbb' };
After: var objec
clang-format: Fix corner case working around one-per-line dict literals.
Before: var object_literal_with_long_name = { a: 'aaaaaaaaaaaaaaaaaa', b: 'bbbbbbbbbbbbbbbbbb' };
After: var object_literal_with_long_name = { a: 'aaaaaaaaaaaaaaaaaa', b: 'bbbbbbbbbbbbbbbbbb' };
llvm-svn: 209296
show more ...
|
#
b16b969d |
| 21-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Support different function literal style.
Before: goog.array.forEach(array, function() { doSomething(); doSomething()
clang-format: [JS] Support different function literal style.
Before: goog.array.forEach(array, function() { doSomething(); doSomething(); }, this);
After: goog.array.forEach(array, function() { doSomething(); doSomething(); }, this);
llvm-svn: 209291
show more ...
|
#
069e5f48 |
| 20-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Understand top-level function literals properly.
llvm-svn: 209205
|
#
0dd5291e |
| 19-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Support ES6 destructuring assignments.
Before: var[a, b, c] = [1, 2, 3];
After: var [a, b, c] = [1, 2, 3];
llvm-svn: 209113
|
#
78214397 |
| 19-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Support for EC6 arrow functions.
Before: var b = a.map((x) = > x + 1);
After: var b = a.map((x) => x + 1);
llvm-svn: 209112
|
Revision tags: llvmorg-3.4.2, llvmorg-3.4.2-rc1 |
|
#
fb4333b0 |
| 12-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Basic support for escape sequences in regex literals.
Before: var regex = /\\/ g; // This isn't even recognized as regex.
After: var regex = /\\/g; // It now is.
llvm-svn: 2
clang-format: [JS] Basic support for escape sequences in regex literals.
Before: var regex = /\\/ g; // This isn't even recognized as regex.
After: var regex = /\\/g; // It now is.
llvm-svn: 208539
show more ...
|
#
89519082 |
| 09-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Fix spacing in dict literals.
Before: someVariable = {'a':[{}]};
After: someVariable = {'a': [{}]};
llvm-svn: 208403
|
#
04a71a45 |
| 08-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Initial support for try-catch.
Most of this patch was created by Alexander Rojas in http://reviews.llvm.org/D2555 Thank you!
Synced and addressed review comments.
llvm-svn: 208302
|
#
c03e16a7 |
| 08-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] support closures in container literals.
Before: return {body: {setAttribute: function(key, val) {this[key] = val; } , getAttribute : function(key) { return this[key]; } ,
clang-format: [JS] support closures in container literals.
Before: return {body: {setAttribute: function(key, val) {this[key] = val; } , getAttribute : function(key) { return this[key]; } , style : { direction: '' } } } ;
After: return { body: { setAttribute: function(key, val) { this[key] = val; }, getAttribute: function(key) { return this[key]; }, style: {direction: ''} } };
llvm-svn: 208292
show more ...
|
#
f7405c12 |
| 08-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Support regex literals after 'return'.
llvm-svn: 208285
|
#
f9ae312f |
| 08-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Initial support for regex literals.
llvm-svn: 208281
|
#
79dffb41 |
| 07-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Be slightly more aggressive on single-line functions.
So that JS functions can also be merged into a single line.
Before: var func = function() { return 1; };
After: var fu
clang-format: Be slightly more aggressive on single-line functions.
So that JS functions can also be merged into a single line.
Before: var func = function() { return 1; };
After: var func = function() { return 1; };
llvm-svn: 208176
show more ...
|
#
484033b1 |
| 06-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Keep space after closure style comments.
Before: var x = /** @type {foo} */ (bar);
After: var x = /** @type {foo} */(bar);
llvm-svn: 208093
|
#
166c19bd |
| 06-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Keep space between 'return' and '['.
llvm-svn: 208090
|
#
4a39c84c |
| 06-May-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: [JS] Don't indent in goog.scope blocks.
Before: goog.scope(function() { var x = a.b; var y = c.d; }); // goog.scope
After: goog.scope(function() { var x = a.b; var
clang-format: [JS] Don't indent in goog.scope blocks.
Before: goog.scope(function() { var x = a.b; var y = c.d; }); // goog.scope
After: goog.scope(function() { var x = a.b; var y = c.d; }); // goog.scope
llvm-svn: 208088
show more ...
|
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 ...
|
Revision tags: llvmorg-3.4.1-rc1 |
|
#
514ecc8c |
| 02-Feb-2014 |
Nico Weber <nicolasweber@gmx.de> |
clang-format: Let chromium style inherit google style's javascript tweaks.
llvm-svn: 200652
|
#
86fee2fa |
| 31-Jan-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: (JavaScript) Don't crash on empty string literals.
Before, this would lead to a crash: f('', true);
llvm-svn: 200540
|
#
b2e10a54 |
| 15-Jan-2014 |
Daniel Jasper <djasper@google.com> |
clang-format: Fixed formatting of JavaScript container literals
Before: var arr = [ 1, 2, 3 ]; var obj = {a : 1, b : 2, c : 3};
After: var arr = [1, 2, 3]; var obj = {a: 1, b: 2, c: 3};
ll
clang-format: Fixed formatting of JavaScript container literals
Before: var arr = [ 1, 2, 3 ]; var obj = {a : 1, b : 2, c : 3};
After: var arr = [1, 2, 3]; var obj = {a: 1, b: 2, c: 3};
llvm-svn: 199317
show more ...
|