4 Printing
(require a86/printer) | package: a86 |
procedure
(asm-display is) → void?
is : (listof instruction?)
Prints an a86 program to the current output port in NASM syntax.
Examples
> (asm-display (prog (Global 'entry) (Label 'entry) (Mov 'rax 42) (Ret)))
default rel
section .text
global $entry
$entry:
mov rax, 42
ret
procedure
(asm-string is) → string?
is : (listof instruction?)
Converts an a86 program to a string in NASM syntax.
Examples
> (asm-string (prog (Global 'entry) (Label 'entry) (Mov 'rax 42) (Ret))) " default rel\n section .text\n global $entry\n$entry:\n mov rax, 42\n ret\n"