summaryrefslogtreecommitdiffstats
path: root/clang/include
diff options
context:
space:
mode:
Diffstat (limited to 'clang/include')
-rw-r--r--clang/include/clang/AST/DeclObjC.h16
1 files changed, 10 insertions, 6 deletions
diff --git a/clang/include/clang/AST/DeclObjC.h b/clang/include/clang/AST/DeclObjC.h
index 74f0a25c316..3ee0b9532a8 100644
--- a/clang/include/clang/AST/DeclObjC.h
+++ b/clang/include/clang/AST/DeclObjC.h
@@ -226,8 +226,7 @@ class ObjCInterfaceDecl : public TypeDecl {
SourceLocation AtEndLoc; // marks the end of the entire interface.
ObjCInterfaceDecl(SourceLocation atLoc, unsigned numRefProtos,
- IdentifierInfo *Id, bool FD = false,
- bool isInternal = false)
+ IdentifierInfo *Id, bool FD, bool isInternal)
: TypeDecl(ObjCInterface, atLoc, Id, 0), SuperClass(0),
ReferencedProtocols(0), NumReferencedProtocols(0), Ivars(0),
NumIvars(-1),
@@ -429,16 +428,21 @@ class ObjCProtocolDecl : public NamedDecl {
SourceLocation EndLoc; // marks the '>' or identifier.
SourceLocation AtEndLoc; // marks the end of the entire interface.
-public:
+
ObjCProtocolDecl(SourceLocation L, unsigned numRefProtos,
- IdentifierInfo *Id, bool FD = false)
+ IdentifierInfo *Id, bool FD)
: NamedDecl(ObjCProtocol, L, Id),
ReferencedProtocols(0), NumReferencedProtocols(0),
InstanceMethods(0), NumInstanceMethods(-1),
ClassMethods(0), NumClassMethods(-1),
isForwardProtoDecl(FD) {
- AllocReferencedProtocols(numRefProtos);
- }
+ AllocReferencedProtocols(numRefProtos);
+ }
+public:
+ static ObjCProtocolDecl *Create(ASTContext &C, SourceLocation L,
+ unsigned numRefProtos, IdentifierInfo *Id,
+ bool ForwardDecl = false);
+
void AllocReferencedProtocols(unsigned numRefProtos) {
if (numRefProtos) {
ReferencedProtocols = new ObjCProtocolDecl*[numRefProtos];
OpenPOWER on IntegriCloud