diff options
author | Abramo Bagnara <abramo.bagnara@gmail.com> | 2012-07-09 21:15:43 +0000 |
---|---|---|
committer | Abramo Bagnara <abramo.bagnara@gmail.com> | 2012-07-09 21:15:43 +0000 |
commit | 34f60a4a7fb87e9f4dfd08f8751ce76db9981215 (patch) | |
tree | 19a125744306c282614a621f2fe64458f30b56dc /lib/AST | |
parent | 6749ae1dbcc9e45ade21b05c6542a6354903ad77 (diff) |
The delete argument should not be converted to void*.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@159961 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST')
-rw-r--r-- | lib/AST/ExprCXX.cpp | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/lib/AST/ExprCXX.cpp b/lib/AST/ExprCXX.cpp index a7240e6978..73347b2e01 100644 --- a/lib/AST/ExprCXX.cpp +++ b/lib/AST/ExprCXX.cpp @@ -127,13 +127,6 @@ SourceLocation CXXNewExpr::getEndLoc() const { // CXXDeleteExpr QualType CXXDeleteExpr::getDestroyedType() const { const Expr *Arg = getArgument(); - while (const ImplicitCastExpr *ICE = dyn_cast<ImplicitCastExpr>(Arg)) { - if (ICE->getCastKind() != CK_UserDefinedConversion && - ICE->getType()->isVoidPointerType()) - Arg = ICE->getSubExpr(); - else - break; - } // The type-to-delete may not be a pointer if it's a dependent type. const QualType ArgType = Arg->getType(); |