aboutsummaryrefslogtreecommitdiff
path: root/debug.inc
diff options
context:
space:
mode:
authorChristian Cunningham <cc@localhost>2024-07-14 09:54:54 -0700
committerChristian Cunningham <cc@localhost>2024-07-14 09:54:54 -0700
commitf4c8ec9028f19fe334ecd4ae49521011fcdba012 (patch)
tree78d8a98ebfbfeb16777076ee17dd297b019b13a1 /debug.inc
parent7d7f6aee29067234baecd771637f123f928f0bf0 (diff)
Single Linked List Impl
Diffstat (limited to 'debug.inc')
-rw-r--r--debug.inc14
1 files changed, 14 insertions, 0 deletions
diff --git a/debug.inc b/debug.inc
index 52a1509..230c7e8 100644
--- a/debug.inc
+++ b/debug.inc
@@ -6,6 +6,12 @@
%ifndef DTOS_INC
%include "dtos.inc"
%endif
+%ifndef MONAD_INC
+%include "monad.inc"
+%endif
+
+ section .data
+ m_make debug_register
;; TODO: Make print without newlineg
%macro DEBUG_HERE 0-1 ""
@@ -23,4 +29,12 @@
lea rax, [rel %%text]
call print_zstring
%endm
+
+%macro REGD 0-2 rax,h
+ section .text
+ lea rax, [%1]
+ m_return rel m_debug_register
+ m_bind data_to_zstring_m%2
+ m_call print_zstring
+%endm
%endif