diff options
author | Alan Modra <amodra@gmail.com> | 2012-12-17 00:16:49 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2012-12-17 00:16:49 +0000 |
commit | 4194268f43623a5f893b9a92b0456d3cb43ab915 (patch) | |
tree | d3c470f3494ea65b44f5ca7d69aa1640c93ace2e /ld/ldexp.h | |
parent | faa7371af5014736b1c67cc7bd0cbcca3353a953 (diff) | |
download | gdb-4194268f43623a5f893b9a92b0456d3cb43ab915.zip gdb-4194268f43623a5f893b9a92b0456d3cb43ab915.tar.gz gdb-4194268f43623a5f893b9a92b0456d3cb43ab915.tar.bz2 |
PR ld/14962
* ldexp.h (struct ldexp_control): Add "assign_name".
* ldexp.c (fold_name <NAME>): Compare and clear assign_name on match.
(exp_fold_tree_1): Remove existing code testing for self assignment.
Instead set and test expld.assign_name.
* ldlang.c (scan_for_self_assignment): Delete.
(print_assignment): Instead set and test expld.assign_name.
Diffstat (limited to 'ld/ldexp.h')
-rw-r--r-- | ld/ldexp.h | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -139,6 +139,11 @@ struct ldexp_control { /* Principally used for diagnostics. */ bfd_boolean assigning_to_dot; + /* If evaluating an assignment, the destination. Cleared if an + etree_name NAME matches this, to signal a self-assignment. + Note that an etree_name DEFINED does not clear this field, nor + does the false branch of a trinary expression. */ + const char *assign_name; /* Working results. */ etree_value_type result; |