| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
dictionary literal
if we can see the elements of the arrays.
for example:
NSDictionary *dict = [NSDictionary dictionaryWithObjects:[NSArray arrayWithObjects:@"1", @"2", nil] forKeys:[NSArray arrayWithObjects:@"A", @"B", nil]];
-->
NSDictionary *dict = @{ @"A" : @"1", @"B" : @"2" };
rdar://12428166
llvm-svn: 172679
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
consider (sub)module visibility.
The bulk of this change replaces myriad hand-rolled loops over the
linked list of Objective-C categories/extensions attached to an
interface declaration with loops using one of the four new category
iterator kinds:
visible_categories_iterator: Iterates over all visible categories
and extensions, hiding any that have their "hidden" bit set. This is
by far the most commonly used iterator.
known_categories_iterator: Iterates over all categories and
extensions, ignoring the "hidden" bit. This tends to be used for
redeclaration-like traversals.
visible_extensions_iterator: Iterates over all visible extensions,
hiding any that have their "hidden" bit set.
known_extensions_iterator: Iterates over all extensions, whether
they are visible to normal name lookup or not.
The effect of this change is that any uses of the visible_ iterators
will respect module-import visibility. See the new tests for examples.
Note that the old accessors for categories and extensions are gone;
there are *Raw() forms for some of them, for those (few) areas of the
compiler that have to manipulate the linked list of categories
directly. This is generally discouraged.
Part two of <rdar://problem/10634711>.
llvm-svn: 172665
|
|
|
|
|
|
| |
Avoid a cast-away-const error by properly using const_cast<>.
llvm-svn: 172558
|
|
|
|
| |
llvm-svn: 172528
|
|
|
|
|
|
|
|
|
|
|
| |
http://llvm-reviews.chandlerc.com/D269
"Added dumping of declaration comments in ASTDumper. This required moving the
comment dumping code from CommentDumper so that the indentation is correct."
Patch by Philip Craig!
llvm-svn: 172409
|
|
|
|
| |
llvm-svn: 172370
|
|
|
|
|
|
| |
brought into 'clang' namespace by clang/Basic/LLVM.h
llvm-svn: 172323
|
|
|
|
| |
llvm-svn: 172317
|
|
|
|
| |
llvm-svn: 172316
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The testcase in pr14929 shows that this is extremely hard to do. If we choose
to apply the attribute, that causes the visibility of some decls to change and
that can happen really late (during codegen).
Current gcc warns and ignores the attribute in this testcase with a warning.
This suggest that the correct solution is to find a point in the compilation
where we can compute the visibility and
* assert it was never computed before
* reject any attempts to compute it again in the future (with warnings).
llvm-svn: 172305
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
which a particular declaration resides. Use this information to
customize the "definition of 'blah' must be imported from another
module" diagnostic with the module the user actually has to
import. Additionally, recover by importing that module, so we don't
complain about other names in that module.
Still TODO: coming up with decent Fix-Its for these cases, and expand
this recovery approach for other name lookup failures.
llvm-svn: 172290
|
|
|
|
|
|
|
| |
of their own (or are syntheszed), use prperty's comment.
for them. // rdar://12791315
llvm-svn: 172278
|
|
|
|
|
|
|
| |
import incomplete definitions for RecordDecls and then
mark the resulting definition as complete.
llvm-svn: 172273
|
|
|
|
|
|
|
|
|
| |
in case condition type. // rdar://11577384.
Test is conditionalized on x86_64-apple triple as
I am not sure if the INT_MAX/LONG_MAX values in the test
will pass this test for other hosts.
llvm-svn: 172016
|
|
|
|
|
|
| |
Modified from a patch by David Greene.
llvm-svn: 171982
|
|
|
|
|
|
| |
Fixes pr14861.
llvm-svn: 171978
|
|
|
|
|
|
| |
Fixes pr14835.
llvm-svn: 171857
|
|
|
|
|
|
|
| |
bits from the number of parameters. This brings the bitfields down from 33 bits
to 32 bits, reducing the size of Types by 4 bytes on 32-bit systems.
llvm-svn: 171827
|
|
|
|
|
|
| |
related to // rdar://12958878
llvm-svn: 171792
|
|
|
|
|
|
|
| |
list of classes, etc., make sure to look into protocol
definitions. // rdar://12958878
llvm-svn: 171777
|
|
|
|
|
|
|
|
| |
http://llvm-reviews.chandlerc.com/D234
Patch by Philip Craig!
llvm-svn: 171760
|
|
|
|
|
|
|
|
|
|
| |
with respect to the lower "left-hand-side bitwidth" bits, even when negative);
see OpenCL spec 6.3j. This patch both implements this behaviour in the code
generator and "constant folding" bits of Sema, and also prevents tests
to detect undefinedness in terms of the weaker C99 or C++ specifications
from being applied.
llvm-svn: 171755
|
|
|
|
|
|
|
| |
It is somewhat hard to test linkage, so I decided to try to add an assert. This
already found some interesting cases where there were different.
llvm-svn: 171585
|
|
|
|
|
|
| |
Thanks for dgregor for noticing it.
llvm-svn: 171532
|
|
|
|
| |
llvm-svn: 171521
|
|
|
|
|
|
|
| |
to match those foung in objc.h an avoid spurious warnings.
// rdar://12489098
llvm-svn: 171492
|
|
|
|
|
|
| |
nearby 'C++0x' comments.
llvm-svn: 171372
|
|
|
|
| |
llvm-svn: 171367
|
|
|
|
| |
llvm-svn: 171354
|
|
|
|
|
|
| |
This gives an about 1.8% improvement on Clang bootstrap with -Wdocumentation
llvm-svn: 171262
|
|
|
|
|
|
| |
the extern "C".
llvm-svn: 171260
|
|
|
|
| |
llvm-svn: 171239
|
|
|
|
| |
llvm-svn: 171238
|
|
|
|
|
|
|
|
| |
This patch moves hasCLanguageLinkage to be VarDecl and FunctionDecl methods
so that they can be used from SemaOverload.cpp and then fixes the logic
in Sema::IsOverload.
llvm-svn: 171193
|
|
|
|
| |
llvm-svn: 171192
|
|
|
|
| |
llvm-svn: 171191
|
|
|
|
|
|
|
|
| |
Changed getLocStart() and getLocEnd() to be required for Stmts, and make
getSourceRange() optional. The default implementation for getSourceRange()
is build the range by calling getLocStart() and getLocEnd().
llvm-svn: 171067
|
|
|
|
|
|
| |
calling convention is already implemented in LLVM.
llvm-svn: 171056
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
the body of a functions. The problem was that hasBody looks at the entire chain
and causes problems to -fvisibility-inlines-hidden if the cache was not
invalidated.
Original message:
Cache visibility of decls.
This unifies the linkage and visibility caching. I first implemented this when
working on pr13844, but the previous fixes removed the performance advantage of
this one.
This is still a step in the right direction for making linkage and visibility
cheap to use.
llvm-svn: 171053
|
|
|
|
|
|
| |
It broke stage2.
llvm-svn: 171050
|
|
|
|
|
|
|
|
|
|
|
| |
This unifies the linkage and visibility caching. I first implemented this when
working on pr13844, but the previous fixes removed the performance advantage of
this one.
This is still a step in the right direction for making linkage and visibility
cheap to use.
llvm-svn: 171048
|
|
|
|
|
|
|
| |
case we can't find an exact width to use. Fixes crash in
<rdar://problem/12456626>.
llvm-svn: 170951
|
|
|
|
|
|
|
|
|
| |
found by running -ast-print on all-std-headers.cpp
which caused it to go into infinite loop. Now
-ast-print prints all declarations found in
all-std-headers.cpp.
llvm-svn: 170928
|
|
|
|
|
|
| |
which is wrong here.
llvm-svn: 170721
|
|
|
|
| |
llvm-svn: 170688
|
|
|
|
|
|
|
|
| |
http://llvm-reviews.chandlerc.com/D226
Patch by Philip Craig!
llvm-svn: 170684
|
|
|
|
|
|
|
| |
appears to currently be benign (we happen to test the flags in the right
order, so we never depend on the uninitialized value).
llvm-svn: 170640
|
|
|
|
|
|
| |
Fixes PR14628.
llvm-svn: 170639
|
|
|
|
|
|
|
|
| |
produce a note for that diagnostic either with a different DiagnosticEngine or
after calling DiagnosticEngine::Reset(). That didn't make any sense, and did the
wrong thing if the original diagnostic was suppressed.
llvm-svn: 170636
|
|
|
|
|
|
|
|
| |
http://llvm-reviews.chandlerc.com/D52
Patch by Philip Craig!
llvm-svn: 170634
|