| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
| |
injected class name of a class template or class template partial specialization.
This is a non-canonical type; the canonical type is still a template
specialization type. This becomes the TypeForDecl of the pattern declaration,
which cleans up some amount of code (and complicates some other parts, but
whatever).
Fixes PR6326 and probably a few others, primarily by re-establishing a few
invariants about TypeLoc sizes.
llvm-svn: 98134
|
|
|
|
|
|
|
| |
This allows them to be allocated using a BumpPtrAllocated
in the common case.
llvm-svn: 97978
|
|
|
|
|
|
| |
pointer types. Fixes radar 7626768.
llvm-svn: 97847
|
|
|
|
|
|
| |
come back to bite us at some point.
llvm-svn: 97607
|
|
|
|
|
|
|
|
|
|
|
| |
category. Use this in a few places to eliminate unnecessary TST cases and
do some future-proofing. Provide terrible manglings for typeof. Mangle
decltype with some hope of accuracy.
Our manglings for some of the cases covered in the testcase are different
from gcc's, which I've raised as an issue with the ABI list.
llvm-svn: 97523
|
|
|
|
|
|
| |
bogus warning. Fixes radar 7682116.
llvm-svn: 97157
|
|
|
|
|
|
|
| |
__alignof__ operator, make sure to take into account the packed alignment
of the struct/union/class itself. Matches GCC's behavior and fixes PR6362.
llvm-svn: 96884
|
|
|
|
| |
llvm-svn: 96850
|
|
|
|
|
|
|
|
| |
fixing up a few callers that thought they were propagating NoReturn
information but were in fact saying something about exception
specifications.
llvm-svn: 96766
|
|
|
|
|
|
| |
instead relies on their DeclContext for iteration, etc.
llvm-svn: 96638
|
|
|
|
|
|
| |
accept const decls.
llvm-svn: 96325
|
|
|
|
|
|
|
| |
a qualified objective-c pointer type. Fixes radar 7638810.
(Also removes a FIXME).
llvm-svn: 96003
|
|
|
|
|
|
| |
ASTContext::getFunctionType with the wrong set of arguments.
llvm-svn: 95986
|
|
|
|
|
|
|
|
|
| |
storing the set of StoredDeclsMaps in an internal vector of void*.
This isn't an ideal solution, but for the time being this fixes a
major memory leak with these DenseMaps not being freed.
Fixes: <rdar://problem/7634755>
llvm-svn: 95861
|
|
|
|
|
|
| |
Decl subclasses. No functionality change.
llvm-svn: 95841
|
|
|
|
|
|
|
| |
and CXXRecordDecl::getDefinition(); it's totally unnecessary. No
functionality change.
llvm-svn: 95836
|
|
|
|
|
|
| |
I don't have time to refix it for now.
llvm-svn: 95733
|
|
|
|
|
|
|
| |
ObjCObjectPointerType AST node by allocating the list of protocols
after the type node itself. No functionality change.
llvm-svn: 95597
|
|
|
|
|
|
|
|
|
| |
attribute properly and avoid bogus warning. This is
an objective-c fix only. objective-c++ follows different code
pass and requires separate fix (which will come at a later time).
Fixes radar 7214820.
llvm-svn: 95571
|
|
|
|
|
|
|
|
|
|
|
|
| |
follows (as conservatively as possible) gcc's current behavior: attributes
written on return types that don't apply there are applied to the function
instead, etc. Only parse CC attributes as type attributes, not as decl attributes;
don't accepet noreturn as a decl attribute on ValueDecls, either (it still
needs to apply to other decls, like blocks). Consistently consume CC/noreturn
information throughout codegen; enforce this by removing their default values
in CodeGenTypes::getFunctionInfo().
llvm-svn: 95436
|
|
|
|
|
|
| |
Fixes latent and not-so-latent objc++ and blocks++ bugs.
llvm-svn: 95340
|
|
|
|
| |
llvm-svn: 95335
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
ton of potential crashes of the same kind. The fundamental problem is
that type creation was following a dangerous pattern when using its
FoldingSets:
1) Use FindNodeOrInsertPos to see if the type is available
2) If not, and we aren't looking at a canonical type, build the
canonical type
3) Build and insert the new node into the FoldingSet
The problem here is that building the canonical type can, in very rare
circumstances, force the hash table inside the FoldingSet to
reallocate. That invalidates the insertion position we computed in
step 1, and in step 3 we end up inserting the new node into the wrong
place. BOOM!
I've audited all of ASTContext, fixing this problem everywhere I found
it. The vast majority of wrong code was C++-specific (and *ahem*
written by me), so I also audited other major folding sets in the C++
code (e.g., template specializations), but found no other instances of
this problem.
llvm-svn: 95315
|
|
|
|
| |
llvm-svn: 95291
|
|
|
|
|
|
|
| |
remove some age-old FIXMEs and C++ workarounds within the
type-compatibility logic.
llvm-svn: 95249
|
|
|
|
|
|
|
| |
with a function with a prototype, treat parameters of enumeration type
based on the enumeration type's promotion type.
llvm-svn: 95238
|
|
|
|
|
|
|
| |
now that the "InBytes" part of the name is implied by the return type, rename
it to getDeclAlign().
llvm-svn: 94681
|
|
|
|
|
|
|
|
| |
sync compare_and_swap to match them with gcc.
It also fixes a few incorrect argument defitions.
(fixes radar 7540291).
llvm-svn: 94607
|
|
|
|
|
|
| |
getTypeAlignInChars().
llvm-svn: 94553
|
|
|
|
|
|
| |
units.
llvm-svn: 94552
|
|
|
|
|
|
|
|
| |
ObjCObjectPointerType using the allocator associated with ASTContext.
Not only does this fix a memory leak, but it also makes these arrays
BumpPtrAllocated (in the typical case).
llvm-svn: 94090
|
|
|
|
|
|
|
| |
Change LookupResult to use UnresolvedSet. Also extract UnresolvedSet into its
own header and make it templated over an inline capacity.
llvm-svn: 93959
|
|
|
|
| |
llvm-svn: 93726
|
|
|
|
|
|
|
| |
correctly look through arrays to see cv-qualifiers. Also enhances the routine
for doing this to preserve more type sugaring for diagnostics.
llvm-svn: 93252
|
|
|
|
|
|
| |
are in characters.
llvm-svn: 93171
|
|
|
|
|
|
|
|
|
|
| |
"ASTContext::getTypeSize() / 8". Replace [u]int64_t variables with CharUnits
ones as appropriate.
Also rename RawType, fromRaw(), and getRaw() in CharUnits to QuantityType,
fromQuantity(), and getQuantity() for clarity.
llvm-svn: 93153
|
|
|
|
|
|
| |
ASTContext::hasSameUnqualifiedType() when one of the type is VariableArrayType.
llvm-svn: 92723
|
|
|
|
| |
llvm-svn: 92715
|
|
|
|
| |
llvm-svn: 92318
|
|
|
|
|
|
|
|
|
|
| |
more or less cv-qualified than another during implicit conversion and overload
resolution ([basic.type.qualifier] p5). Factors the logic out of template
deduction and into the ASTContext so it can be shared.
This fixes several aspects of PR5542, but not all of them.
llvm-svn: 92248
|
|
|
|
| |
llvm-svn: 92246
|
|
|
|
| |
llvm-svn: 92162
|
|
|
|
|
|
|
|
| |
for loops. Also do not manually free the Type objects when the
'FreeMemory' flag is set, as they will be deallocated when the
BumpPtrAllocator is destroyed.
llvm-svn: 92047
|
|
|
|
|
|
| |
avoid #including CharUnits.h in ASTContext.h.
llvm-svn: 91903
|
|
|
|
| |
llvm-svn: 91189
|
|
|
|
|
|
| |
recently introduced crash.
llvm-svn: 91070
|
|
|
|
|
|
|
|
|
|
|
|
| |
"integer promotion" type associated with an enum decl, and use this type to
determine which type to promote to. This type obeys C++ [conv.prom]p2 and
is therefore generally signed unless the range of the enumerators forces
it to be unsigned.
Kills off a lot of false positives from -Wsign-compare in C++, addressing
rdar://7455616
llvm-svn: 90965
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
pointers thereof) to their corresponding non-noreturn function
types. This conversion is considered an exact match for
overload-resolution purposes. Note that we are a little more strict
that GCC is, because we encode noreturn in the type system, but that's
a Good Thing (TM) because it does not allow us to pretend that
potentially-returning function pointers are non-returning function
pointers.
Fxies PR5620.
llvm-svn: 90913
|
|
|
|
| |
llvm-svn: 90745
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
variables,
but the results are imperfect.
For posterity, I did:
cat <<EOF > $cmdfile
s/DeclaratorInfo/TypeSourceInfo/g
s/DInfo/TInfo/g
s/TypeTypeSourceInfo/TypeSourceInfo/g
s/SourceTypeSourceInfo/TypeSourceInfo/g
EOF
find lib -name '*.cpp' -not -path 'lib/Parse/*' -exec sed -i '' -f $cmdfile '{}' \;
find lib -name '*.h' -exec sed -i '' -f $cmdfile '{}' \;
find include -name '*.h' -not -path 'include/clang/Parse/*' -not -path 'include/clang/Basic/*' -exec sed -i '' -f $cmdfile '{}' \;
llvm-svn: 90743
|