home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
World of A1200
/
World_Of_A1200.iso
/
programs
/
text
/
jed
/
src
/
jed.lha
/
sprintf.a
< prev
next >
Wrap
Text File
|
1992-10-20
|
865b
|
46 lines
; SPRINTF.A
;
; RawDoFmt() string formatters.
section text,code
xref _LVORawDoFmt
;Prototype VOID sprintf(STRPTR, STRPTR, ...);
xdef _sprintf
_sprintf:
movem.l a2-a3/a6,-(sp)
move.l 20(sp),a0
lea 24(sp),a1
move.l 16(sp),a3
lea stuffit(pc),a2
move.l 4.w,a6
jsr _LVORawDoFmt(a6)
movem.l (sp)+,a2-a3/a6
rts
; The registerized arg conventions are those used by DICE, this means
; that this routine will probably have to be altered for SAS, etc...
;
;Prototype VOID vsprintf(STRPTR, STRPTR, APTR);
; a0 a1 d0
xdef _vsprintf
xdef @vsprintf
_vsprintf: ; in case I don't use -mRR
movem.l 4(sp),a0-a1
move.l 12(sp),d0
@vsprintf:
movem.l a2-a3/a6,-(sp)
move.l a0,a3
move.l a1,a0
move.l d0,a1
lea stuffit(pc),a2
move.l 4.w,a6
jsr _LVORawDoFmt(a6)
movem.l (sp)+,a2-a3/a6
rts
stuffit:
move.b d0,(a3)+
rts