From 6f7f67b1b4d1d124822e29ae669f1e8107de8f1b Mon Sep 17 00:00:00 2001 From: Joseph Hunkeler Date: Tue, 19 Jun 2018 00:48:26 -0400 Subject: Implement TAB --- stdio.asm | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'stdio.asm') diff --git a/stdio.asm b/stdio.asm index 23d2ac9..161d1a3 100644 --- a/stdio.asm +++ b/stdio.asm @@ -218,6 +218,9 @@ printf: .parse_control: lodsb ; get next byte + cmp al, 't' ; TAB + je .do_TAB + cmp al, 'n' ; new line je .do_LF @@ -226,6 +229,11 @@ printf: jmp .do_default + .do_TAB: + mov ax, ASCII_TAB + call putc + jmp .main_string + .do_LF: mov ax, ASCII_CR ; home the line call putc -- cgit