remove one more old-style Diag method.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@59589 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp
index 5864f22..94fca00 100644
--- a/lib/Sema/SemaExprCXX.cpp
+++ b/lib/Sema/SemaExprCXX.cpp
@@ -156,8 +156,8 @@
   // be a class with a suitably declared constructor.
   //
   if (NumExprs > 1)
-    return Diag(CommaLocs[0], diag::err_builtin_func_cast_more_than_one_arg,
-                FullRange);
+    return Diag(CommaLocs[0], diag::err_builtin_func_cast_more_than_one_arg)
+      << FullRange;
 
   assert(NumExprs == 0 && "Expected 0 expressions");
 
@@ -167,10 +167,10 @@
   // rvalue of the specified type, which is value-initialized.
   //
   if (Ty->isArrayType())
-    return Diag(TyBeginLoc, diag::err_value_init_for_array_type, FullRange);
+    return Diag(TyBeginLoc, diag::err_value_init_for_array_type) << FullRange;
   if (Ty->isIncompleteType() && !Ty->isVoidType())
-    return Diag(TyBeginLoc, diag::err_invalid_incomplete_type_use,
-                Ty.getAsString(), FullRange);
+    return Diag(TyBeginLoc, diag::err_invalid_incomplete_type_use) 
+      << Ty.getAsString() << FullRange;
 
   return new CXXZeroInitValueExpr(Ty, TyBeginLoc, RParenLoc);
 }
@@ -199,11 +199,11 @@
   if (Ty->isFunctionType()) { // The declarator shall not specify a function...
     // We exit without creating a CXXConditionDeclExpr because a FunctionDecl
     // would be created and CXXConditionDeclExpr wants a VarDecl.
-    return Diag(StartLoc, diag::err_invalid_use_of_function_type,
-                SourceRange(StartLoc, EqualLoc));
+    return Diag(StartLoc, diag::err_invalid_use_of_function_type)
+      << SourceRange(StartLoc, EqualLoc);
   } else if (Ty->isArrayType()) { // ...or an array.
-    Diag(StartLoc, diag::err_invalid_use_of_array_type,
-         SourceRange(StartLoc, EqualLoc));
+    Diag(StartLoc, diag::err_invalid_use_of_array_type)
+      << SourceRange(StartLoc, EqualLoc);
   } else if (const RecordType *RT = Ty->getAsRecordType()) {
     RecordDecl *RD = RT->getDecl();
     // The type-specifier-seq shall not declare a new class...