* typeck.c (build_c_cast): Check that the destination type is
complete.
PR c++/10635
* g++.dg/expr/cast1.C: New test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@67840
138bc75d-0d04-0410-961f-
82ee72b054a4
+2003-06-12 Mark Mitchell <mark@codesourcery.com>
+
+ PR c++/10635
+ * typeck.c (build_c_cast): Check that the destination type is
+ complete.
+
2003-06-11 Mark Mitchell <mark@codesourcery.com>
PR c++/10432
value = convert_to_void (value, /*implicit=*/NULL);
return value;
}
+
+ if (!complete_type_or_else (type, NULL_TREE))
+ return error_mark_node;
+
/* Convert functions and arrays to pointers and
convert references to their expanded types,
but don't convert any other types. If, however, we are
+2003-06-12 Mark Mitchell <mark@codesourcery.com>
+
+ PR c++/10635
+ * g++.dg/expr/cast1.C: New test.
+
2003-06-12 Roger Sayle <roger@eyesopen.com>
* gcc.dg/builtins-21.c: New test case.
--- /dev/null
+struct S; // { dg-error "forward" }
+
+void f(S* p) { ((S) (*p)); } // { dg-error "" }