summaryrefslogtreecommitdiff
path: root/macros.asm
diff options
context:
space:
mode:
Diffstat (limited to 'macros.asm')
-rw-r--r--macros.asm12
1 files changed, 12 insertions, 0 deletions
diff --git a/macros.asm b/macros.asm
index 4370886b2..ca62491eb 100644
--- a/macros.asm
+++ b/macros.asm
@@ -149,3 +149,15 @@ bcd: MACRO
shift
endr
ENDM
+
+ln: MACRO
+ if _NARG == 5
+ lb \1, \2 << 4 + \3, \4 << 4 + \5
+ else
+ if _NARG == 3
+ ld \1, \2 << 4 + \3
+ else
+ fail "incorrect number of arguments for ln"
+ endc
+ endc
+ENDM