[SemaCXX11 patch] Patch to prevent a crash when attempting to call a 'deleted' constructor
jahanian
fjahanian at apple.com
Mon Apr 13 15:54:08 PDT 2015
This patch fixes a crash in release build clang and produces the desired diagnostic.
In the debug build clang it does not crash but produces a misleading diagnostic.
Problem is that in TryUserDefinedConversion(…)
We have:
case OR_Deleted:
// ….
if (CXXConstructorDecl *Constructor
= dyn_cast<CXXConstructorDecl>(ICS.UserDefined.ConversionFunction)) {
// …
}
And ICS.UserDefined.ConversionFunction never gets set for a ‘delete’ constructor.
Please review.
- Fariborz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20150413/6724c581/attachment.html>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch.txt
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20150413/6724c581/attachment.txt>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20150413/6724c581/attachment-0001.html>
More information about the cfe-commits
mailing list