| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
| |
llvm-svn: 43362
|
|
|
|
|
|
|
| |
Changed the entire rewrite of metadata to write to std::string
object instead of stdout.
llvm-svn: 43360
|
|
|
|
|
|
| |
printf as an example.
llvm-svn: 43346
|
|
|
|
| |
llvm-svn: 43344
|
|
|
|
|
|
| |
some code.
llvm-svn: 43322
|
|
|
|
|
|
|
|
| |
metadata emission.
Implemented emission of category metadata,
llvm-svn: 43308
|
|
|
|
| |
llvm-svn: 43274
|
|
|
|
|
|
|
| |
- Add setter/getter to ObjcClassDecl.
- Predefined key runtime functions.
llvm-svn: 43257
|
|
|
|
| |
llvm-svn: 43233
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I didn't realize that GCC considers this a hard error (I thought it was built-in).
Since it's not, we should simply emit an error.
[dylan:~/llvm/tools/clang] admin% cc -c trivial.m
trivial.m:6: error: cannot find interface declaration for 'NSConstantString'
[administrators-powerbook59:~/llvm/tools/clang] admin% ../../Debug/bin/clang trivial.m
trivial.m:6:16: error: cannot find interface declaration for 'NSConstantString'
NSString *s = @"123";
^
1 diagnostic generated.
llvm-svn: 43157
|
|
|
|
| |
llvm-svn: 43139
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
unsigned char asso_values[] = { 34 };
int legal2() {
return asso_values[0];
}
The code that creates the new constant array type was operating on the original type.
As a result, the constant type being generated was "unsigned char [1][]" (which is wrong).
The fix is to operate on the element type - in this case, the correct type is "unsigned char [1]"
I added this case to array-init.c, which clearly didn't catch this bogosity...
llvm-svn: 43112
|
|
|
|
| |
llvm-svn: 43054
|
|
|
|
| |
llvm-svn: 43051
|
|
|
|
|
|
|
|
| |
Rename SourceRange::Begin()/End() to getBegin()/getEnd() for
consistency with other code.
Start building the rewriter towards handling @encode.
llvm-svn: 43047
|
|
|
|
| |
llvm-svn: 43046
|
|
|
|
|
|
| |
#import to #include's as a test.
llvm-svn: 43041
|
|
|
|
| |
llvm-svn: 43038
|
|
|
|
|
|
| |
Sema::InitBuiltinVaListType (which had the same bug).
llvm-svn: 43023
|
|
|
|
| |
llvm-svn: 43022
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
predicates are now instance methods (they were previously static class methods on Type).
This allowed me to fix the following hack from this weekend...
// FIXME: Devise a way to do this without using strcmp.
// Would like to say..."return getAsStructureType() == IdStructType;", but
// we don't have a pointer to ASTContext.
bool Type::isObjcIdType() const {
if (const RecordType *RT = getAsStructureType())
return !strcmp(RT->getDecl()->getName(), "objc_object");
return false;
}
...which is now...
bool isObjcIdType(QualType T) const {
return T->getAsStructureType() == IdStructType;
}
Side notes:
- I had to remove a convenience function from the TypesCompatibleExpr class.
int typesAreCompatible() const {return Type::typesAreCompatible(Type1,Type2);}
Which required a couple clients get a little more verbose...
- Result = TCE->typesAreCompatible();
+ Result = Ctx.typesAreCompatible(TCE->getArgType1(), TCE->getArgType2());
Overall, I think this change also makes sense for a couple reasons...
1) Since ASTContext vends types, it makes sense for the type compatibility API to be there.
2) This allows the type compatibility predeciates to refer to data not strictly present in the AST (which I have found problematic on several occasions).
llvm-svn: 43009
|
|
|
|
| |
llvm-svn: 42974
|
|
|
|
|
|
| |
insert stuff.
llvm-svn: 42941
|
|
|
|
| |
llvm-svn: 42936
|
|
|
|
|
|
| |
decl will only be 0 when we have an error on the ObjC decl. I would prefer we pass in a decl that is marked as invalid. I don't think this is critical to fix now, however I'd like us to be consistent. There are currently many places that don't mark the decl as invalid (which need to be fixed)...
llvm-svn: 42923
|
|
|
|
|
|
| |
and hid them.
llvm-svn: 42915
|
|
|
|
| |
llvm-svn: 42863
|
|
|
|
| |
llvm-svn: 42856
|
|
|
|
|
|
|
|
|
| |
- Cache the typedef, not the type (avoids importing AST/Type.h).
- Emit an error if "id" cannot be found.
- Comment the routine and add a FIXME to reconsider how we emulate GCC's new fangled behavior. This isn't a priority for now, since almost no code depends on having "id" built-in.
- Add a test.
llvm-svn: 42845
|
|
|
|
| |
llvm-svn: 42840
|
|
|
|
|
|
| |
place and making it correctly parameterized on the target.
llvm-svn: 42830
|
|
|
|
|
|
|
|
|
|
| |
This fixes a crasher in Sema::MatchTwoMethodDeclarations(), identified by selector-overload.m (just added).
Added Action::ActOnTranslationUnitScope() and renamed Action::PopScope to ActOnPopScope.
Added a Translation Unit Scope instance variable to Sema (will be very useful to ObjC-related actions, since ObjC declarations are always file-scoped).
llvm-svn: 42817
|
|
|
|
|
|
|
| |
DenseMap to keep track of such declarations and derive ObjcProtocolDecl
directyly from NamedScope.
llvm-svn: 42801
|
|
|
|
| |
llvm-svn: 42797
|
|
|
|
|
|
|
|
| |
ParseFunctionDefinition so that ActOnFunctionDefBody is always
called if ActOnStartOfFunctionDef is called. This fixes a crash
reported by Nuno Lopes.
llvm-svn: 42793
|
|
|
|
|
|
|
| |
Protocols are now sorted and made unique in the list.
Enhanced pretty printer for @interface (So, I can see the protocol list).
llvm-svn: 42776
|
|
|
|
| |
llvm-svn: 42773
|
|
|
|
| |
llvm-svn: 42770
|
|
|
|
|
|
| |
DenseMapInfo in IdentifierTable.h).
llvm-svn: 42767
|
|
|
|
|
|
|
| |
ObjcProtocolDecl is now derived from ScopedDecl. ObjcForwardProtocolDecl from Decl.
ObjcImplementationDecl fom NamedDecl.
llvm-svn: 42756
|
|
|
|
| |
llvm-svn: 42730
|
|
|
|
| |
llvm-svn: 42718
|
|
|
|
|
|
| |
stringmap operations when there are no secondary targets.
llvm-svn: 42688
|
|
|
|
|
|
|
|
| |
- Added include/Analysis/ExprDeclBitVector.h
- Added include/Analysis/ProgramEdge.h
- Removed include/Analysis/Visitors/DataflowStmtVisitor.h
llvm-svn: 42663
|
|
|
|
|
|
|
| |
objective-c types. It also removes use of Scope* parameter in
getObjCProtocolDecl.
llvm-svn: 42649
|
|
|
|
|
|
|
|
|
|
|
| |
- Add SelectorTable, which enables us to remove MultiKeywordSelector from the public header.
- Remove FoldingSet from IdentifierInfo.h and Preprocessor.h.
- Remove Parser::ObjcGetUnarySelector and Parser::ObjcGetKeywordSelector, they are subsumed by SelectorTable.
- Add MultiKeywordSelector to IdentifierInfo.cpp.
- Move a bunch of selector related methods from ParseObjC.cpp to IdentifierInfo.cpp.
- Added some comments.
llvm-svn: 42643
|
|
|
|
|
|
| |
2) Use of the new DenseSet<t> abstractions instead of DenseMap<t,char>.
llvm-svn: 42641
|
|
|
|
| |
llvm-svn: 42608
|
|
|
|
| |
llvm-svn: 42603
|
|
|
|
|
|
| |
fixed consequence of these changes in clang.
llvm-svn: 42600
|