+2015-11-26 Eric Botcazou <ebotcazou@adacore.com>
+
+ PR c++/68527
+ * c-ada-spec.c (dump_nested_types): Add guard for error_mark_node.
+ (print_ada_struct_decl): Likewise.
+
2015-11-23 Igor Zamyatin <igor.zamyatin@intel.com>
PR c++/68001
field = TYPE_FIELDS (outer);
while (field)
{
- if ((TREE_TYPE (field) != outer
+ if (((TREE_TYPE (field) != outer
+ && TREE_TYPE (field) != error_mark_node)
|| (TREE_CODE (TREE_TYPE (field)) == POINTER_TYPE
&& TREE_TYPE (TREE_TYPE (field)) != outer))
&& (!TYPE_NAME (TREE_TYPE (field))
}
}
/* Avoid printing the structure recursively. */
- else if ((TREE_TYPE (tmp) != node
- || (TREE_CODE (TREE_TYPE (tmp)) == POINTER_TYPE
- && TREE_TYPE (TREE_TYPE (tmp)) != node))
+ else if (((TREE_TYPE (tmp) != node
+ && TREE_TYPE (tmp) != error_mark_node)
+ || (TREE_CODE (TREE_TYPE (tmp)) == POINTER_TYPE
+ && TREE_TYPE (TREE_TYPE (tmp)) != node))
&& TREE_CODE (tmp) != TYPE_DECL
&& !TREE_STATIC (tmp))
{