|
From: anonymous c. <nas...@us...> - 2010-10-04 13:25:49
|
> %push > > %assign %$arg 8 > > %macro local 0 > %xdefine %[%:] ebp-%[%$arg] > %assign %$arg %$arg+8 > %endmacro > > _main: > > .myvar local ; results in _main.myvar defined as ebp-8 > mov rax, [.myvar] > > %pop > > I personally prefer the %: syntax as it is slightly less confusing than %00. > However, bear in mind that previous snippet is modifying the local label > for it's own use and that this behavior should continue being supported > following any syntax change. Yes, that would still work, of course. 1 <0> %push c 2 <0> 3 = 0000000000000008h <0> %assign %$arg 8 4 <0> 5 <0> %macro local 0 6 <0> %definex %: bp-%$arg 7 <0> %assign %$arg %$arg+8 8 <0> %endmacro 9 <0> 10 <0> _main: 11 <0> 12 <0> .myvar: local 13 <1> %definex .myvar bp-%$arg 14 = 0000000000000010h <1> %assign %$arg %$arg+8 15 0000000000000000 8B46F8 <0> mov ax, [.myvar] 16 <0> 17 <0> .myvar2: local 18 <1> %definex .myvar2 bp-%$arg 19 = 0000000000000018h <1> %assign %$arg %$arg+8 20 0000000000000003 8B46F0 <0> mov ax, [.myvar2] 21 <0> 22 = "c" <0> %pop Ignore that %xdefine is named %definex for me. |