[cfe-commits] r136161 - in /cfe/trunk: include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/SemaExprCXX.cpp test/SemaCXX/new-delete.cpp

Sean Hunt scshunt at csclub.uwaterloo.ca
Tue Jul 26 15:28:48 PDT 2011


On Tue, Jul 26, 2011 at 15:25, Eli Friedman <eli.friedman at gmail.com> wrote:
> Author: efriedma
> Date: Tue Jul 26 17:25:31 2011
> New Revision: 136161
>
> URL: http://llvm.org/viewvc/llvm-project?rev=136161&view=rev
> Log:
> A couple minor issues with Sema for delete:
>
> 1. Attempting to delete an expression of incomplete class type should be an error, not a warning.
>
> 2. If someone tries to delete a pointer to an incomplete class type, make sure we actually emit
> the delete expression after we warn.

Deleting an object of incomplete class type is well-formed;
[expr.delete]/5. This should not be an error.

Sean



More information about the cfe-commits mailing list