diff options
author | Tristan Gingold <gingold@adacore.com> | 2012-03-08 13:53:03 +0000 |
---|---|---|
committer | Tristan Gingold <gingold@adacore.com> | 2012-03-08 13:53:03 +0000 |
commit | 67baf8c476074caad96ac5ed7ff990904e5678de (patch) | |
tree | 4f4cd4551b3149bbea9da99eecf90d3806fcf0fa | |
parent | 007cafee35df423a7d61a5b366311d10c7312e25 (diff) | |
download | fsf-binutils-gdb-67baf8c476074caad96ac5ed7ff990904e5678de.zip fsf-binutils-gdb-67baf8c476074caad96ac5ed7ff990904e5678de.tar.gz fsf-binutils-gdb-67baf8c476074caad96ac5ed7ff990904e5678de.tar.bz2 |
2012-03-08 Tristan Gingold <gingold@adacore.com>
* ldexp.c (exp_print_tree): Special case for SEGMENT_START.
(exp_print_token): Constify.
-rw-r--r-- | ld/ChangeLog | 5 | ||||
-rw-r--r-- | ld/ldexp.c | 13 |
2 files changed, 17 insertions, 1 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog index a0a0d2b..daba2fd 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,8 @@ +2012-03-08 Tristan Gingold <gingold@adacore.com> + + * ldexp.c (exp_print_tree): Special case for SEGMENT_START. + (exp_print_token): Constify. + 2012-03-08 Alan Modra <amodra@gmail.com> PR ld/10340 @@ -59,7 +59,7 @@ exp_print_token (token_code_type code, int infix_p) static const struct { token_code_type code; - char * name; + const char * name; } table[] = { @@ -1145,6 +1145,17 @@ exp_print_tree (etree_type *tree) case DATA_SEGMENT_ALIGN: case DATA_SEGMENT_RELRO_END: function_like = TRUE; + break; + case SEGMENT_START: + /* Special handling because arguments are in reverse order and + the segment name is quoted. */ + exp_print_token (tree->type.node_code, FALSE); + fputs (" (\"", config.map_file); + exp_print_tree (tree->binary.rhs); + fputs ("\", ", config.map_file); + exp_print_tree (tree->binary.lhs); + fputc (')', config.map_file); + return; } if (function_like) { |