.TITLE ASKDPS ; ; .IDENT /Y07.00/ ; ; ; .ENABL LC ; ; ; Copyright (C) Shell Research Ltd. 1983 ; ; ; The copyright in this computer program and associated user ; instructions contained in this document is the property of ; Shell Research Ltd.. No guarantee is given or may be implied ; as to the adequacy of the program or its suitability for any ; particular purpose and no liability is accepted for any loss ; or damage arising out of its use. ; ; ; ; Version: Y07 ; ; ; Author: R J Carpenter 21-Mar-83 ; ; ; Revised: Ray Carpenter 29-Feb-84 ; ; .page .sbttl code ; ; .psect $ask$ ; askdps:: tst (r5) ;any arguments supplied ? beq exit ;br if not cmp 2(r5),#-1 ;valid addr. ? beq exit ;br if not mov 2(r5),r0 ;use r0 as pointer mov #qprmpt,r1 ;set up prompt string addr. in r1 mov #3,r2 ;use r2 as loop counter clr iplen ;new prompt length 10$: tstb (r0) ;end of string ? beq exit ;br if yes movb (r0)+,(r1)+ ;copy a byte inc iplen ;new prompt length dec r2 ;dec loop count bne 10$ ;br if not all done ; exit: return ;return to caller ; ; .end