test/map.asm
raw| 1 | %define foo(x) (x+1) |
| 2 | %define bar(=x,y) (x*y) |
| 3 | %define baz(x+) %(x) |
| 4 | dw %map(foo,1,2,3,4) |
| 5 | dw %map(bar::2,1+2,3+4,5+6,7+8) |
| 6 | dw %map(baz::2,1+2,3+4,5+6,7+8) |
| 7 | |
| 8 | bar equ 8 |
| 9 | quux equ 4 |
| 10 | %define alpha(&x) x |
| 11 | %define alpha(&x,y) y dup (x) |
| 12 | %define alpha(s,&x,y) y dup (x,s) |
| 13 | db %map(alpha,foo,bar,baz,quux) |
| 14 | db %map(alpha::2,foo,bar,baz,quux) |
| 15 | db %map(alpha:("!"):2,foo,bar,baz,quux) |