[C++ Patch] PR 51225
Paolo Carlini
paolo.carlini@oracle.com
Fri Jan 13 18:18:00 GMT 2012
Hi,
in C++11 mode after erroring out for an undeclared name we can easily
end up calling cxx_eval_constant_expression on a CAST_EXPR etc, which
has error_mark_node as argument.
The latter trees are currently completely unhandled by
cxx_eval_constant_expression, thus in order to avoid such ICEs on
invalid it seems safe setting *non_constant_p = true and returning back
t, as we do when t itself is error_mark_node, and asserting errorcount.
The resulting diagnostics is pretty terse.
Tested x86_64-linux.
Thanks,
Paolo.
////////////////
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: CL_51225
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20120113/82720670/attachment.ksh>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch_51225
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20120113/82720670/attachment-0001.ksh>
More information about the Gcc-patches
mailing list