adjust to change in SmallSet interface

llvm-svn: 39313
This commit is contained in:
Chris Lattner 2007-01-27 02:14:08 +00:00
parent 67521df9a8
commit baf33665fb
4 changed files with 5 additions and 6 deletions

View File

@ -475,7 +475,7 @@ void Sema::ParseRecordBody(SourceLocation RecLoc, DeclTy *RecDecl,
// Keep track of the number of named members.
if (IdentifierInfo *II = FD->getIdentifier()) {
// Detect duplicate member names.
if (!FieldIDs.insert(II).second) {
if (!FieldIDs.insert(II)) {
Diag(FD->getLocation(), diag::err_duplicate_member, II->getName());
// Find the previous decl.
SourceLocation PrevLoc;
@ -520,7 +520,6 @@ Sema::DeclTy *Sema::ParseEnumConstant(Scope *S, DeclTy *EnumDeclX,
}
}
TypeRef Ty = Context.getTagDeclType(TheEnumDecl);
EnumConstantDecl *New = new EnumConstantDecl(IdLoc, Id, Ty);

View File

@ -367,6 +367,7 @@ void DiagnosticPrinterSTDERR::HandleDiagnostic(Diagnostic::Level Level,
SourceLocation Pos,
diag::kind ID,
const std::string &Extra) {
return;
++NumDiagnostics;
unsigned LineNo = 0, FilePos = 0, FileID = 0, ColNo = 0;
unsigned LineStart = 0, LineEnd = 0;

View File

@ -1024,7 +1024,7 @@ void Parser::ParseParenDeclarator(Declarator &D) {
IdentifierInfo *ParmII = Tok.getIdentifierInfo();
// Verify that the argument identifier has not already been mentioned.
if (!ParamsSoFar.insert(ParmII).second) {
if (!ParamsSoFar.insert(ParmII)) {
Diag(Tok.getLocation(), diag::err_param_redefinition,ParmII->getName());
ParmII = 0;
}
@ -1103,7 +1103,7 @@ void Parser::ParseParenDeclarator(Declarator &D) {
IdentifierInfo *ParmII = ParmDecl.getIdentifier();
// Verify that the argument identifier has not already been mentioned.
if (ParmII && !ParamsSoFar.insert(ParmII).second) {
if (ParmII && !ParamsSoFar.insert(ParmII)) {
Diag(ParmDecl.getIdentifierLoc(), diag::err_param_redefinition,
ParmII->getName());
ParmII = 0;

View File

@ -475,7 +475,7 @@ void Sema::ParseRecordBody(SourceLocation RecLoc, DeclTy *RecDecl,
// Keep track of the number of named members.
if (IdentifierInfo *II = FD->getIdentifier()) {
// Detect duplicate member names.
if (!FieldIDs.insert(II).second) {
if (!FieldIDs.insert(II)) {
Diag(FD->getLocation(), diag::err_duplicate_member, II->getName());
// Find the previous decl.
SourceLocation PrevLoc;
@ -520,7 +520,6 @@ Sema::DeclTy *Sema::ParseEnumConstant(Scope *S, DeclTy *EnumDeclX,
}
}
TypeRef Ty = Context.getTagDeclType(TheEnumDecl);
EnumConstantDecl *New = new EnumConstantDecl(IdLoc, Id, Ty);