History log of /llvm-project/clang/lib/Format/Format.cpp (Results 551 – 575 of 1154)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 553a5b00 02-Jul-2015 Daniel Jasper <djasper@google.com>

clang-format: [JS] Fix character counting in template strings.

Some counts were off, we don't need to take the leading newlines of the
first ` into account and some tests were just wrong.

llvm-svn:

clang-format: [JS] Fix character counting in template strings.

Some counts were off, we don't need to take the leading newlines of the
first ` into account and some tests were just wrong.

llvm-svn: 241257

show more ...


# a0388a8a 29-Jun-2015 Birunthan Mohanathas <birunthan@mohanathas.com>

clang-format: Add option to break after definition return type for top-level functions only

Differential Revision: http://reviews.llvm.org/D10774

llvm-svn: 240959


# a081002b 29-Jun-2015 Birunthan Mohanathas <birunthan@mohanathas.com>

clang-format: Adjust Mozilla style defaults

Summary: This makes the Mozilla style defaults more compliant with the Mozilla style guide. A few options were removed in order to use the LLVM style defa

clang-format: Adjust Mozilla style defaults

Summary: This makes the Mozilla style defaults more compliant with the Mozilla style guide. A few options were removed in order to use the LLVM style defaults.

Differential Revision: http://reviews.llvm.org/D10771

llvm-svn: 240957

show more ...


# 50a6f915 28-Jun-2015 Birunthan Mohanathas <birunthan@mohanathas.com>

clang-format: Stop old options from overriding new options

Summary: Depends on D10785.

Reviewers: djasper

Reviewed By: djasper

Subscribers: klimek, cfe-commits

Differential Revision: http://revi

clang-format: Stop old options from overriding new options

Summary: Depends on D10785.

Reviewers: djasper

Reviewed By: djasper

Subscribers: klimek, cfe-commits

Differential Revision: http://reviews.llvm.org/D10786

llvm-svn: 240909

show more ...


# 35cfbd79 28-Jun-2015 Birunthan Mohanathas <birunthan@mohanathas.com>

clang-format: Alphabetize FormatStyle members

Reviewers: djasper

Reviewed By: djasper

Subscribers: klimek, cfe-commits

Differential Revision: http://reviews.llvm.org/D10784

llvm-svn: 240907


Revision tags: llvmorg-3.6.2
# 6b8d26c2 24-Jun-2015 Daniel Jasper <djasper@google.com>

clang-format: [JS] Support regex literals containing quotes (' and ").

llvm-svn: 240548


Revision tags: llvmorg-3.6.2-rc1
# ab9db510 22-Jun-2015 Alexander Kornienko <alexfh@google.com>

Revert r240270 ("Fixed/added namespace ending comments using clang-tidy").

llvm-svn: 240353


# 3d9d929e 22-Jun-2015 Alexander Kornienko <alexfh@google.com>

Fixed/added namespace ending comments using clang-tidy. NFC

The patch is generated using this command:

$ tools/extra/clang-tidy/tool/run-clang-tidy.py -fix \
-checks=-*,llvm-namespace-comme

Fixed/added namespace ending comments using clang-tidy. NFC

The patch is generated using this command:

$ tools/extra/clang-tidy/tool/run-clang-tidy.py -fix \
-checks=-*,llvm-namespace-comment -header-filter='llvm/.*|clang/.*' \
work/llvm/tools/clang

To reduce churn, not touching namespaces spanning less than 10 lines.

llvm-svn: 240270

show more ...


# e6fcf7d3 17-Jun-2015 Daniel Jasper <djasper@google.com>

clang-format: clang-format (NFC)

llvm-svn: 239903


# 2ebb0c57 14-Jun-2015 Daniel Jasper <djasper@google.com>

clang-format: [JS] Fix corner case in template string parsing.

Before, these would not properly detected because of the char/string
literal found when re-lexing after the first `:

var x = `'`; /

clang-format: [JS] Fix corner case in template string parsing.

Before, these would not properly detected because of the char/string
literal found when re-lexing after the first `:

var x = `'`; // comment with matching quote '
var x = `"`; // comment with matching quote "

llvm-svn: 239693

show more ...


# 229628b3 11-Jun-2015 Daniel Jasper <djasper@google.com>

clang-format: Don't add spaces in foreach macro definition.

Before clang-format would e.g. add a space into

#define Q_FOREACH(x, y)

which turns this into a non-function-like macro.

Patch by St

clang-format: Don't add spaces in foreach macro definition.

Before clang-format would e.g. add a space into

#define Q_FOREACH(x, y)

which turns this into a non-function-like macro.

Patch by Strager Neds, thank you!

llvm-svn: 239513

show more ...


# 21b4117a 02-Jun-2015 Manuel Klimek <klimek@google.com>

Remove error message when using the fallback style.

llvm-svn: 238822


# 79e06081 21-May-2015 Manuel Klimek <klimek@google.com>

clang-format: [JS] Better support for fat arrows.

Assigns a token type (TT_JsFatArrow) to => tokens, and uses that to
more easily recognize and format fat arrow functions.
Improves function parsing

clang-format: [JS] Better support for fat arrows.

Assigns a token type (TT_JsFatArrow) to => tokens, and uses that to
more easily recognize and format fat arrow functions.
Improves function parsing to better recognize formal parameter
lists and return type declarations.
Recognizes arrow functions and parse function bodies as child blocks.

Patch by Martin Probst.

llvm-svn: 237895

show more ...


Revision tags: llvmorg-3.6.1, llvmorg-3.6.1-rc1
# d3585dbd 11-May-2015 Manuel Klimek <klimek@google.com>

Refactor the formatter of clang-format.

Pull various parts of the UnwrappedLineFormatter into their own
abstractions. NFC.

There are two things left for subsequent changes (to keep this
reasonably

Refactor the formatter of clang-format.

Pull various parts of the UnwrappedLineFormatter into their own
abstractions. NFC.

There are two things left for subsequent changes (to keep this
reasonably small)
- the UnwrappedLineFormatter now has a bad name
- the UnwrappedLineFormatter::format function is still too large

llvm-svn: 236974

show more ...


# f0fd1c66 10-May-2015 Daniel Jasper <djasper@google.com>

clang-format: Fix bug in escaped newline calculation.

This prevents clang-format from inadvertently joining stuff into macro
definitions as reported in llvm.org/PR23466.

llvm-svn: 236944


# 69694b06 08-May-2015 Daniel Jasper <djasper@google.com>

clang-format: [JS] Fix regex literal detection.

Before:
var regex = /= / ;

After:
var regex = /=/;

llvm-svn: 236811


# ec5c3db7 07-May-2015 Manuel Klimek <klimek@google.com>

Implements a way to retrieve information about whether some lines were not formatted due to syntax errors.

llvm-svn: 236722


# 24a8f558 06-May-2015 Manuel Klimek <klimek@google.com>

Remove deprecated version of reformat.

llvm-svn: 236594


# 20e0af6b 06-May-2015 Manuel Klimek <klimek@google.com>

Remove all computation of structural errors in clang-format's line parser.

We were already ignoring those already.

llvm-svn: 236591


# e2408e37 06-May-2015 Daniel Jasper <djasper@google.com>

clang-format: Fix another assertion discovered by the fuzzer.

In the process, fix an old todo that I don't really know how to write
tests for. The problem is that Clang's lexer creates very strange

clang-format: Fix another assertion discovered by the fuzzer.

In the process, fix an old todo that I don't really know how to write
tests for. The problem is that Clang's lexer creates very strange token
sequences for these. However, the new approach seems generally better
and easier to read so I am submitting it nonetheless.

llvm-svn: 236589

show more ...


# 66cb8c50 04-May-2015 Daniel Jasper <djasper@google.com>

clang-format: NFC: Delete FormatToken::IsForEachMacro. Use a TokenType instead.

llvm-svn: 236415


# f69b922e 02-May-2015 Daniel Jasper <djasper@google.com>

clang-format: [JS] Fix calculation of template string width.

OriginalColumn might not be set, so fall back to Location and SourceMgr
in case it is missing. Also initialize end column in case the tok

clang-format: [JS] Fix calculation of template string width.

OriginalColumn might not be set, so fall back to Location and SourceMgr
in case it is missing. Also initialize end column in case the token is
multi line, but it's the ` token itself that starts the multi line.

Patch by Martin Probst, thank you!

llvm-svn: 236383

show more ...


# a4499133 29-Apr-2015 Daniel Jasper <djasper@google.com>

clang-format: Add ability to align assignment operators.

In Objective-C some style guides use a style where assignment operators are
aligned, in an effort to increase code readability. This patch ad

clang-format: Add ability to align assignment operators.

In Objective-C some style guides use a style where assignment operators are
aligned, in an effort to increase code readability. This patch adds an option
to the format library which allows this functionality. It is disabled by
default for all the included styles, so it must be explicitly enabled.

The option will change code such as:
- (void)method {
NSNumber *one = @1;
NSNumber *twentyFive = @25;
}

to:
- (void)method {
NSNumber *one = @1;
NSNumber *twentyFive = @25;
}

Patch by Matt Oakes. Thank you!

Accidentally reformatted all the tests...

llvm-svn: 236100

show more ...


# 0d6ac27b 16-Apr-2015 Daniel Jasper <djasper@google.com>

clang-format: [JS] handle comments in template strings.

Patch by Martin Probst. Thank you.

llvm-svn: 235078


# 1662bfe0 03-Apr-2015 Daniel Jasper <djasper@google.com>

clang-format: [Proto] No alternate operator names.

llvm-svn: 234055


1...<<21222324252627282930>>...47