| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
| |
argument lists when the arguments are elided. eg)
__declspec(deprecated()) // error
__declspec(deprecated) // OK
__declspec(deprecated("")) // OK
llvm-svn: 206191
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently the on disk hash table's key_iterator and data_iterator make
the assumption that the table data starts exactly four bytes after the
base of the table. This happens to be true for all of the tables we
currently iterate over, but not for all of the OnDiskHashTables we
currently use. For example, key_ and data_iterator would iterate over
meaningless data if they were used on the hash tables in PTHLexer.
We make the API safer by breaking this into two types. One doesn't
have the iterators, and the other must be told where the payload
starts.
llvm-svn: 206189
|
| |
|
|
|
|
|
| |
No functional change. Style cleanups in OnDiskChainedHashTable in
preparation for some other changes here.
llvm-svn: 206188
|
| |
|
|
|
|
|
|
|
|
|
| |
when the arguments are elided. eg)
[[deprecated()]] // error
[[deprecated]] // OK
[[deprecated("")]] // OK
[[gnu::deprecated()]] // OK
llvm-svn: 206186
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Summary: Add support for named values in the parser.
Reviewers: pcc
CC: cfe-commits, klimek
Differential Revision: http://llvm-reviews.chandlerc.com/D3276
llvm-svn: 206176
|
| |
|
|
| |
llvm-svn: 206173
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Before:
#define A(a, b) (a &&b)
After:
#define A(a, b) (a && b)
This fixes llvm.org/PR19343.
llvm-svn: 206165
|
| |
|
|
|
|
|
| |
Instead of choosing based on the number of elements, simply respect the
user's choice of where to wrap array literals.
llvm-svn: 206162
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Before:
bool aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa GUARDED_BY(
aaaaaaaaaaaa) = aaaaaaaa::aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa;
After:
bool aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa GUARDED_BY(aaaaaaaaaaaa) =
aaaaaaaa::aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa;
llvm-svn: 206155
|
| |
|
|
|
|
|
|
|
|
| |
Parse of nested name spacifier is modified so that it properly recovers
if colon is mistyped as double colon in case statement.
This patch fixes PR15133.
Differential Revision: http://llvm-reviews.chandlerc.com/D2870
llvm-svn: 206135
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the C-style type cast is applied to the overloaded
function and the destination type is function type,
then Clang will crash with assertion failure. For example,
void foo(int);
void foo(int, int);
void bar() {
typedef void (ft)(int);
ft p = (ft)foo;
}
In this case, the overloaded function foo will be cast to
a function type, which should be considered as an error.
But, unfortunately, since the function resolution is using
canonical type, the matched function will be returned, and
result in SEGV.
This patch fixes this issue by removing the assertion and
add some error diagnostics as the one in static_cast.
llvm-svn: 206133
|
| |
|
|
|
|
|
|
|
| |
Don't consider a __declspec(align) on a bitfield's declaration if it didn't
allocate any underlying storage.
This fixes PR19414.
llvm-svn: 206132
|
| |
|
|
|
|
| |
properly.
llvm-svn: 206128
|
| |
|
|
|
|
|
| |
__FUNCDNAME__ was introduced way back in r194181 but I forgot to add
these tests.
llvm-svn: 206125
|
| |
|
|
|
|
|
|
|
|
|
| |
Previously, it was believed that #pragma vtordisp(0) would prohibit the
generation of any and all vtordisps.
In actuality, it only disables the generation of additional vtordisps.
This fixes PR19413.
llvm-svn: 206124
|
| |
|
|
| |
llvm-svn: 206123
|
| |
|
|
|
|
| |
No functionality change.
llvm-svn: 206111
|
| |
|
|
|
|
| |
Target ABI code might add signext to the return types.
llvm-svn: 206107
|
| |
|
|
| |
llvm-svn: 206099
|
| |
|
|
|
|
|
| |
Make sure that templates are handled correctly by profile
instrumentation.
llvm-svn: 206091
|
| |
|
|
|
|
| |
No functional change.
llvm-svn: 206090
|
| |
|
|
|
|
|
|
|
| |
for CXXGlobalInit/Dtor helper functions.
This makes _GLOBAL__I_a regain its DW_AT_high/low_pc in the debug info.
Thanks to echristo for catching this!
llvm-svn: 206088
|
| |
|
|
|
|
|
| |
If a vtordisp exists between two bases, then there is no need for
additional alias avoidance padding. Test case included.
llvm-svn: 206087
|
| |
|
|
|
|
|
|
|
| |
Until now we were generating duplicate counters for lambdas: one set
in the function where the lambda was declared and another for the
lambda itself. Instead, we should skip over the bodies of lambdas in
their containing contexts.
llvm-svn: 206081
|
| |
|
|
|
|
|
|
|
|
| |
A portion of the vtordisp computation that was previously unguarded by a
test for the declaration of user defined constructors/destructors was
erroniously adding vtordisps to things that shouldn't have them. This
patch correctly guards that codepath. In addition, it updates the
comments to make them more clear. Test case is included.
llvm-svn: 206077
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The -fms-extensions option affects a number of subtle front-end C/C++
behaviors, and it would be useful to be able to distinguish MS keywords
from regular identifiers in the ms-extensions mode even if the triple
does not define a Windows target. It should make life easier if anyone
needs to port their Windows codes to elsewhere.
Differential Revision: http://reviews.llvm.org/D3034
llvm-svn: 206069
|
| |
|
|
|
|
|
| |
This avoids the overhead of specifying all the traversal code when using
ConstStmtVisitor and makes it a lot easier to maintain this.
llvm-svn: 206039
|
| |
|
|
|
|
| |
No functionality change.
llvm-svn: 206038
|
| |
|
|
|
|
|
| |
We will need this to correctly handle conflict markers inside macro
definitions.
llvm-svn: 206029
|
| |
|
|
|
| |
Review: http://reviews.llvm.org/D3335
llvm-svn: 206027
|
| |
|
|
|
|
|
| |
This treats binary conditional operators in the same way as ternary
conditional operators for instrumentation based profiling.
llvm-svn: 206021
|
| |
|
|
|
|
| |
Thanks dblaikie for the suggestion!
llvm-svn: 206012
|
| |
|
|
|
|
|
|
|
|
|
| |
declaration is not visible. Previously we didn't find hidden friend names in
this redeclaration lookup, because we forgot to treat it as a redeclaration
lookup. Conversely, we did find some local extern names, but those don't
actually conflict with a namespace-scope using declaration, because the only
conflicts we can get are scope conflicts, not conflicts due to the entities
being members of the same namespace.
llvm-svn: 206011
|
| |
|
|
|
|
|
|
| |
This patch updates the comments in RecordLayoutBuilder about record
layout in the MS-ABI. Also, I added a section about known
incompatibilities.
llvm-svn: 206010
|
| |
|
|
|
|
| |
Responding to Richard Smith's review of r205037.
llvm-svn: 206008
|
| |
|
|
|
|
|
|
|
|
| |
In version 9 (VS2010) (and prior)? versions of msvc, if the last field
in a record was a bitfield padding equal to the size of the storage
class of that bitfield was added before each vbase and vtordisp. This
patch removes that feature from clang and updates the lit tests to
reflect it.
llvm-svn: 206004
|
| |
|
|
|
|
|
|
| |
No functionality change.
<rdar://problem/16435801>
llvm-svn: 206002
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes a bug where unsigned numbers are read using strtol and strtoll.
I don't have a testcase because this bug is effectively unobservable
right now. To expose the problem in the hash, we would need a function
with greater than INT64_MAX counters, which we don't handle anyway. To
expose the problem in the function count, we'd need a function with
greater than INT32_MAX counters; this is theoretically observable, but
it isn't a practical testcase to check in.
An upcoming commit changes the hash to be non-trivial, so we'll get some
coverage eventually.
<rdar://problem/16435801>
llvm-svn: 206001
|
| |
|
|
|
|
|
|
| |
The vbptr is injected after the last non-virtual base lexographically
rather than the last non-virtual base in layout order. Test case
included. Also, some line ending fixes.
llvm-svn: 206000
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
are not associated with any source lines.
Previously, if the Location of a Decl was empty, EmitFunctionStart would
just keep using CurLoc, which would sometimes be correct (e.g., thunks)
but in other cases would just point to a hilariously random location.
This patch fixes this by completely eliminating all uses of CurLoc from
EmitFunctionStart and rather have clients explicitly pass in a
SourceLocation for the function header and the function body.
rdar://problem/14985269
llvm-svn: 205999
|
| |
|
|
|
|
| |
Patch by Alex Crichton!
llvm-svn: 205998
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When __declspec(align()) is applied to a bitfield it affects the
alignment rather than the required alignment of the struct. The major
feature that this patch adds is that the alignment of the structure
obeys the alignment of __declspec(align()) from the bitfield over the
value specified in pragma pack.
Test cases are included.
The patch also includes some small cleanups in recordlayoutbuilder and
some cleanups to some lit tests, including line endings (but no
functionality change to lit tests)
llvm-svn: 205994
|
| |
|
|
|
|
|
| |
This ensures that the overall struct size will be a multiple of 4, as
required by the ABI.
llvm-svn: 205981
|
| |
|
|
|
|
|
|
| |
Emitting the PGO initialization in EmitGlobalFunctionDefinition is
inefficient, since this only has an effect once per module. We move
this to Release() with the rest of the once-per-module logic.
llvm-svn: 205977
|
| |
|
|
|
|
| |
const correctness and reformatting. Fixes the types involved with castOpcode().
llvm-svn: 205976
|
| |
|
|
|
|
|
| |
With the VFS, it is easy to hit modified umbrellas by overriding the
umbrella header, and what we want is to rebuild, not to fail.
llvm-svn: 205975
|
| |
|
|
|
|
| |
No functionality change.
llvm-svn: 205972
|