forked from Imagelibrary/binutils-gdb
* ldlang.c (lang_map): Increment lang_statement_iteration so that DEFINED() expressions are correctly computed.
* testsuite/ld-script/map-address.d, * testsuite/ld-script/map-address.t: Add a test for testing DEFINED in map output.
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
#...
|
||||
Linker script and memory map
|
||||
#...
|
||||
*0x0*000020 *def1 = .*
|
||||
*0x0*000020 *def2 = def1
|
||||
*0x0*010001 *\. = 0x10001
|
||||
*0x0*010001 *foo = \.
|
||||
*0x0*010201 *\. = \(\. \+ 0x200\)
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
SECTIONS
|
||||
{
|
||||
def1 = DEFINED(foo) ? 0x10 : 0x20;
|
||||
def2 = def1;
|
||||
. = 0x10001;
|
||||
foo = .;
|
||||
. += 0x200;
|
||||
|
||||
Reference in New Issue
Block a user