+2004-09-18 Joseph S. Myers <jsm@polyomino.org.uk>
+
+ PR c/17424
+ * c-typeck.c (c_expr_sizeof_expr): Check for error_mark_node.
+
2004-09-18 Diego Novillo <dnovillo@redhat.com>
* tree-ssa-alias.c (setup_pointers_and_addressables): Don't
c_expr_sizeof_expr (struct c_expr expr)
{
struct c_expr ret;
- ret.value = c_sizeof (TREE_TYPE (expr.value));
- ret.original_code = ERROR_MARK;
- pop_maybe_used (C_TYPE_VARIABLE_SIZE (TREE_TYPE (expr.value)));
+ if (expr.value == error_mark_node)
+ {
+ ret.value = error_mark_node;
+ ret.original_code = ERROR_MARK;
+ pop_maybe_used (false);
+ }
+ else
+ {
+ ret.value = c_sizeof (TREE_TYPE (expr.value));
+ ret.original_code = ERROR_MARK;
+ pop_maybe_used (C_TYPE_VARIABLE_SIZE (TREE_TYPE (expr.value)));
+ }
return ret;
}
+2004-09-18 Joseph S. Myers <jsm@polyomino.org.uk>
+
+ PR c/17424
+ * gcc.dg/pr17424-1.c: New test.
+
2004-09-18 Diego Novillo <dnovillo@redhat.com>
* g++.dg/tree-ssa/pr17153.C: New test.