diff options
author | Chris Lattner <sabre@nondot.org> | 2008-11-19 05:27:50 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2008-11-19 05:27:50 +0000 |
commit | dcd5ef12488e4c7ea844327835896ca86b609a97 (patch) | |
tree | 9994fcd4c20c5f77dc2b5e2df9ba26288e4f8ecc /lib/Sema/SemaType.cpp | |
parent | fa25bbb351f4fdd977f51254119cdfc2b525ce90 (diff) |
remove one more old-style Diag method.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@59589 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaType.cpp')
-rw-r--r-- | lib/Sema/SemaType.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/Sema/SemaType.cpp b/lib/Sema/SemaType.cpp index 85c57f53ad..945082ad46 100644 --- a/lib/Sema/SemaType.cpp +++ b/lib/Sema/SemaType.cpp @@ -405,14 +405,14 @@ QualType Sema::GetTypeForDeclarator(Declarator &D, Scope *S) { // have a value greater than zero. if (ConstVal.isSigned()) { if (ConstVal.isNegative()) { - Diag(ArraySize->getLocStart(), - diag::err_typecheck_negative_array_size, - ArraySize->getSourceRange()); + Diag(ArraySize->getLocStart(), + diag::err_typecheck_negative_array_size) + << ArraySize->getSourceRange(); D.setInvalidType(true); } else if (ConstVal == 0) { // GCC accepts zero sized static arrays. - Diag(ArraySize->getLocStart(), diag::ext_typecheck_zero_array_size, - ArraySize->getSourceRange()); + Diag(ArraySize->getLocStart(), diag::ext_typecheck_zero_array_size) + << ArraySize->getSourceRange(); } } T = Context.getConstantArrayType(T, ConstVal, ASM, ATI.TypeQuals); @@ -663,8 +663,8 @@ static void HandleAddressSpaceTypeAttribute(QualType &Type, Expr *ASArgExpr = static_cast<Expr *>(Attr.getArg(0)); llvm::APSInt addrSpace(32); if (!ASArgExpr->isIntegerConstantExpr(addrSpace, S.Context)) { - S.Diag(Attr.getLoc(), diag::err_attribute_address_space_not_int, - ASArgExpr->getSourceRange()); + S.Diag(Attr.getLoc(), diag::err_attribute_address_space_not_int) + << ASArgExpr->getSourceRange(); return; } |