disable copying of Type objects.

llvm-svn: 68103
This commit is contained in:
Chris Lattner 2009-03-31 08:58:42 +00:00
parent 3e2f36e905
commit 6d35cc945f
2 changed files with 3 additions and 1 deletions

View File

@ -287,6 +287,8 @@ private:
/// subclasses can pack their bitfields into the same word.
unsigned TC : 5;
Type(const Type&); // DO NOT IMPLEMENT.
void operator=(const Type&); // DO NOT IMPLEMENT.
protected:
// silence VC++ warning C4355: 'this' : used in base member initializer list
Type *this_() { return this; }

View File

@ -631,7 +631,7 @@ const RecordDecl *ASTContext::addRecordToClass(const ObjCInterfaceDecl *D) {
D->getIdentifier());
/// FIXME! Can do collection of ivars and adding to the record while
/// doing it.
for (unsigned int i = 0; i != RecFields.size(); i++) {
for (unsigned i = 0, e = RecFields.size(); i != e; ++i) {
NewRD->addDecl(FieldDecl::Create(*this, NewRD,
RecFields[i]->getLocation(),
RecFields[i]->getIdentifier(),