Writing a stringAssembler/8086

This is gem is similar to Writing a two-digit number. This time, you can print strings. They do not need to end with a $.
;
; writeln
;
; input:
;   textstring
;
; output:
;   none (text displayed on screen)
;
; destroys:
;   ax, dx
;   flags
;

WRITELN MACRO   _string
LOCAL   _afterstring

        call    _afterstring

db	_string,13,10,'$'
_afterstring:
        mov     ah,9
	pop	dx
	int	21h

        ENDM
To use it, just type:
WriteLN('Hello, world!');
Gem writer: Ervin Toth
last updated: 1998-03-16