From 8caa5e7cafb686ac215eb4d1eb56f8a953ea11f4 Mon Sep 17 00:00:00 2001 From: Christian Cunningham Date: Sun, 14 Jul 2024 09:16:39 -0700 Subject: Whitespace Formatting --- monad.inc | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'monad.inc') diff --git a/monad.inc b/monad.inc index 6c5f676..18d8552 100644 --- a/monad.inc +++ b/monad.inc @@ -4,12 +4,12 @@ %include "alloc.inc" %endif -struc Monad +struc Monad just: resq 1 exist: resb 1 endstruc -%macro m_make 1-3 0,0 +%macro m_make 1-3 0,0 ;; %1 = Name ;; %2 = Address of Structure ;; %3 = Something > 0, Nothing = 0 @@ -20,7 +20,7 @@ m_%1: iend %endm -%macro m_Just 1-3 0,0 +%macro m_Just 1-3 0,0 ;; %1 = Name ;; %2 = New Structure Address ;; %3 = Something > 0, Nothing = 0 @@ -38,16 +38,16 @@ m_%1: lea rax, [%1] %endm -%macro m_Nothing 1 +%macro m_Nothing 1 ;; %1 = Name m_Just %1 %endm -%macro m_return 1-2 rax +%macro m_return 1-2 rax m_Just %1, %2, 1 %endm -%macro m_bind 1-2 rax +%macro m_bind 1-2 rax ;; %1 = Callable Function with Single Argument, the Unwrapped Monad ;; %2 = Monad ;; m a -> (a -> m b) -> m b @@ -61,7 +61,7 @@ m_%1: %%exit: %endmacro -%macro m_call 1-2 rax +%macro m_call 1-2 rax ;; %1 = Callable Function with Single Argument, the Unwrapped Monad ;; %2 = Monad ;; m a -> (a -> !) -> ! @@ -75,11 +75,11 @@ m_%1: %%exit: %endmacro -%macro alloc_m 0 +%macro alloc_m 0 alloc Monad_size %endm -%macro free_m 1 +%macro free_m 0-1 rax free %1, Monad_size %endm -- cgit v1.2.1