aboutsummaryrefslogtreecommitdiff
path: root/lib/Sema/SemaDecl.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-02-20 21:35:13 +0000
committerChris Lattner <sabre@nondot.org>2009-02-20 21:35:13 +0000
commit38af2deb27cdfa1a95bde96e30dab15dce53fcef (patch)
tree59ea0e3b21832285ca2a9cb52c1da38f32813790 /lib/Sema/SemaDecl.cpp
parent11e1e1af2641affb378080a4f3d1a30da1cad082 (diff)
add plumbing to get ASTContext& down to allocation/deallocation points in ObjCList,
but don't start using it yet. Renamed some methods to be more consistent. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65168 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDecl.cpp')
-rw-r--r--lib/Sema/SemaDecl.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Sema/SemaDecl.cpp b/lib/Sema/SemaDecl.cpp
index d91c2c1a19..c7f37fc286 100644
--- a/lib/Sema/SemaDecl.cpp
+++ b/lib/Sema/SemaDecl.cpp
@@ -3688,7 +3688,9 @@ void Sema::ActOnFields(Scope* S,
} else {
ObjCIvarDecl **ClsFields = reinterpret_cast<ObjCIvarDecl**>(&RecFields[0]);
if (ObjCInterfaceDecl *ID = dyn_cast<ObjCInterfaceDecl>(EnclosingDecl)) {
- ID->addInstanceVariablesToClass(ClsFields, RecFields.size(), RBrac);
+ ID->setIVarList(ClsFields, RecFields.size(), Context);
+ ID->setLocEnd(RBrac);
+
// Must enforce the rule that ivars in the base classes may not be
// duplicates.
if (ID->getSuperClass()) {
@@ -3707,7 +3709,7 @@ void Sema::ActOnFields(Scope* S,
else if (ObjCImplementationDecl *IMPDecl =
dyn_cast<ObjCImplementationDecl>(EnclosingDecl)) {
assert(IMPDecl && "ActOnFields - missing ObjCImplementationDecl");
- IMPDecl->setIVarList(ClsFields, RecFields.size());
+ IMPDecl->setIVarList(ClsFields, RecFields.size(), Context);
CheckImplementationIvars(IMPDecl, ClsFields, RecFields.size(), RBrac);
}
}