[cfe-commits] r89885 - /cfe/trunk/lib/Sema/SemaDeclCXX.cpp
Fariborz Jahanian
fjahanian at apple.com
Wed Nov 25 13:53:11 PST 2009
Author: fjahanian
Date: Wed Nov 25 15:53:11 2009
New Revision: 89885
URL: http://llvm.org/viewvc/llvm-project?rev=89885&view=rev
Log:
Better diagnostic on deleted constructor when no
initializer name is available.
Modified:
cfe/trunk/lib/Sema/SemaDeclCXX.cpp
Modified: cfe/trunk/lib/Sema/SemaDeclCXX.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaDeclCXX.cpp?rev=89885&r1=89884&r2=89885&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaDeclCXX.cpp (original)
+++ cfe/trunk/lib/Sema/SemaDeclCXX.cpp Wed Nov 25 15:53:11 2009
@@ -3611,10 +3611,13 @@
Diag(Loc, diag::err_ovl_deleted_init)
<< Best->Function->isDeleted()
<< InitEntity << Range;
- else
+ else {
+ const CXXRecordDecl *RD =
+ cast<CXXRecordDecl>(ClassType->getAs<RecordType>()->getDecl());
Diag(Loc, diag::err_ovl_deleted_init)
<< Best->Function->isDeleted()
- << InitEntity << Range;
+ << RD->getDeclName() << Range;
+ }
PrintOverloadCandidates(CandidateSet, /*OnlyViable=*/true);
return 0;
}
More information about the cfe-commits
mailing list