lang_assignment_statement serves both assignments and asserts.
* ldlang.c (open_input_bfds): Check that lang_assignment_statement
is not an assert before referencing defsym.
+2017-03-07 Alan Modra <amodra@gmail.com>
+
+ * ldlang.c (open_input_bfds): Check that lang_assignment_statement
+ is not an assert before referencing defsym.
+
2017-03-05 Alan Modra <amodra@gmail.com>
* testsuite/ld-elf/eh3.d: Adjust for eh_frame alignment change.
#endif
break;
case lang_assignment_statement_enum:
- if (s->assignment_statement.exp->assign.defsym)
+ if (s->assignment_statement.exp->type.node_class != etree_assert
+ && s->assignment_statement.exp->assign.defsym)
/* This is from a --defsym on the command line. */
exp_fold_tree_no_dot (s->assignment_statement.exp);
break;