aboutsummaryrefslogtreecommitdiff
path: root/tests/unused_macro_arg.s
diff options
context:
space:
mode:
authorMiquel Sabaté Solà <mssola@mssola.com>2026-07-07 23:51:17 +0200
committerMiquel Sabaté Solà <mssola@mssola.com>2026-07-07 23:51:17 +0200
commit5fca76b56034554d965b77d1485f92685d79bc84 (patch)
tree425aee9ff95f2d41974b1e7d06df201f4263b5cd /tests/unused_macro_arg.s
parent2b1356d371b52d68243ddebbfcf3f65047c2fd76 (diff)
downloadtools.nes-5fca76b56034554d965b77d1485f92685d79bc84.tar.gz
tools.nes-5fca76b56034554d965b77d1485f92685d79bc84.zip
Let arguments be able to reference their macro
The enum type for macro arguments has been adjusted so it accepts a String. This is then used to store the name of the macro for this argument. This is a bit of a circlejerk, but in the end it stems from the fact that macro arguments were sort of a hack defined ad-hoc each time they were needed. That being said, if we want to report macro arguments being unused, we need to reference the actual macro definition, not the macro call. Signed-off-by: Miquel Sabaté Solà <mssola@mssola.com>
Diffstat (limited to 'tests/unused_macro_arg.s')
-rw-r--r--tests/unused_macro_arg.s4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/unused_macro_arg.s b/tests/unused_macro_arg.s
index fe4d7f0..ef75a23 100644
--- a/tests/unused_macro_arg.s
+++ b/tests/unused_macro_arg.s
@@ -8,7 +8,7 @@
;;; asan:stack full
-.macro BCD_ADD ADDR
+.macro BCD_ADD ADDR, OTHER
adc ADDR
bcc :+
nop
@@ -16,7 +16,7 @@
.endmacro
.proc add_to_player_y
- BCD_ADD additions
+ BCD_ADD additions, 2
rts