* mangle.c (write_expression): Issue a sorry for zero-operand
functional casts.
From-SVN: r84899
+2004-07-18 Mark Mitchell <mark@codesourcery.com>
+
+ * mangle.c (write_expression): Issue a sorry for zero-operand
+ functional casts.
+
2004-07-18 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
PR c++/13092
case CAST_EXPR:
write_type (TREE_TYPE (expr));
- write_expression (TREE_VALUE (TREE_OPERAND (expr, 0)));
+ /* There is no way to mangle a zero-operand cast like
+ "T()". */
+ if (!TREE_OPERAND (expr, 0))
+ sorry ("zero-operand casts cannot be mangled due to a defect "
+ "in the C++ ABI");
+ else
+ write_expression (TREE_VALUE (TREE_OPERAND (expr, 0)));
break;
case STATIC_CAST_EXPR: