summaryrefslogtreecommitdiff
path: root/macros
diff options
context:
space:
mode:
authorvulcandth <vulcandth@gmail.com>2022-03-26 21:05:06 -0500
committerGitHub <noreply@github.com>2022-03-26 22:05:06 -0400
commitfbaa5c9d4b48c000a52860a8392fc423c4e312f9 (patch)
tree80c5d8b0458ab6a2c2f1995ed0addd1f6cb5570f /macros
parenta178c57f021692e442febfff4e592a9be8687a33 (diff)
Build the Virtual Console patch with `make yellow_vc` (#80)
Diffstat (limited to 'macros')
-rw-r--r--macros/vc.asm27
1 files changed, 27 insertions, 0 deletions
diff --git a/macros/vc.asm b/macros/vc.asm
new file mode 100644
index 00000000..2fbdf9d6
--- /dev/null
+++ b/macros/vc.asm
@@ -0,0 +1,27 @@
+vc_hook: MACRO
+IF DEF(_YELLOW_VC)
+.VC_\1::
+ENDC
+ENDM
+
+vc_patch: MACRO
+IF DEF(_YELLOW_VC)
+ ASSERT !DEF(CURRENT_VC_PATCH), "Already started a vc_patch"
+CURRENT_VC_PATCH EQUS "\1"
+.VC_{CURRENT_VC_PATCH}::
+ENDC
+ENDM
+
+vc_patch_end: MACRO
+IF DEF(_YELLOW_VC)
+ ASSERT DEF(CURRENT_VC_PATCH), "No vc_patch started"
+.VC_{CURRENT_VC_PATCH}_End::
+ PURGE CURRENT_VC_PATCH
+ENDC
+ENDM
+
+vc_assert: MACRO
+IF DEF(_YELLOW_VC)
+ ASSERT \#
+ENDC
+ENDM