diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2009-06-30 02:36:12 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2009-06-30 02:36:12 +0000 |
commit | 17945a0f64fe03ff6ec0c2146005a87636e3ac12 (patch) | |
tree | 76e53886f0d07ed0cd801ee8820e3f0abca65991 /lib/CodeGen/CGExprConstant.cpp | |
parent | 048f30a483ca352ee7f235a5be181b9dcc5f9d9c (diff) |
De-ASTContext-ify DeclContext.
Remove ASTContext parameter from DeclContext's methods. This change cascaded down to other Decl's methods and changes to call sites started "escalating".
Timings using pre-tokenized "cocoa.h" showed only a ~1% increase in time run between and after this commit.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@74506 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExprConstant.cpp')
-rw-r--r-- | lib/CodeGen/CGExprConstant.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/CodeGen/CGExprConstant.cpp b/lib/CodeGen/CGExprConstant.cpp index 0b109f9bee..37c9c366fe 100644 --- a/lib/CodeGen/CGExprConstant.cpp +++ b/lib/CodeGen/CGExprConstant.cpp @@ -199,8 +199,8 @@ public: // Copy initializer elements. Skip padding fields. unsigned EltNo = 0; // Element no in ILE bool RewriteType = false; - for (RecordDecl::field_iterator Field = RD->field_begin(CGM.getContext()), - FieldEnd = RD->field_end(CGM.getContext()); + for (RecordDecl::field_iterator Field = RD->field_begin(), + FieldEnd = RD->field_end(); EltNo < ILE->getNumInits() && Field != FieldEnd; ++Field) { if (Field->isBitField()) { if (!Field->getIdentifier()) @@ -263,8 +263,8 @@ public: // Make sure that it's really an empty and not a failure of // semantic analysis. RecordDecl *RD = ILE->getType()->getAsRecordType()->getDecl(); - for (RecordDecl::field_iterator Field = RD->field_begin(CGM.getContext()), - FieldEnd = RD->field_end(CGM.getContext()); + for (RecordDecl::field_iterator Field = RD->field_begin(), + FieldEnd = RD->field_end(); Field != FieldEnd; ++Field) assert(Field->isUnnamedBitfield() && "Only unnamed bitfields allowed"); #endif |