home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / C / MAXONC3_6OF8.DMS / in.adf / LIBSRC.LHA / LIBSRC / stream_longint.asm < prev    next >
Encoding:
Assembly Source File  |  1994-04-16  |  1.1 KB  |  64 lines

  1. *
  2. *    Maxon C++:
  3. *
  4. *    Library-Modul "stream_longint"
  5. *
  6. *    Jens Gelhar 22.04.92, 16.04.94
  7. *
  8.  
  9.     xdef    op__leftshift__ostream__Tl,op__leftshift__ostream__TUl
  10.  
  11.     xref    _vlongtostr,_uvlongtostr,op__leftshift__ostream__TPCc
  12.  
  13. op__leftshift__ostream__Tl:    ; Stack-Parameter: ostream&, long long
  14.     move.l a0,-(a7)
  15.     move.l 8(a7),a0
  16.     lea -54(a7),a7
  17.     move.l a0,-(a7)
  18.     move.w #10,-(a7)
  19.     move.l (a0),a0
  20.     move.b 4(a0),d0
  21.     cmp.b #8,d0
  22.     beq.b tl1
  23.     cmp.b #16,d0
  24.     bne.b tl2
  25. tl1    move.b d0,1(a7)
  26. tl2    pea 2+8(a7)
  27.     move.l 6+58+8+8(a7),-(a7)
  28.     move.l 6+58+8+8(a7),-(a7)
  29.     jsr _vlongtostr
  30.     lea 14(a7),a7
  31.     move.l d0,4(a7)
  32.     jsr op__leftshift__ostream__TPCc
  33.     lea 50+8(a7),a7
  34.     move.l (a7)+,a0
  35.     move.l 4(a7),d0
  36.     rts
  37.  
  38. op__leftshift__ostream__TUl:    ; Stack-Parameter: ostream&, unsigned long long
  39.     move.l a0,-(a7)
  40.     move.l 8(a7),a0
  41.     lea -50-4(a7),a7
  42.     move.l a0,-(a7)
  43.     move.w #10,-(a7)
  44.     move.l (a0),a0
  45.     move.b 4(a0),d0
  46.     cmp.b #8,d0
  47.     beq.b tul1
  48.     cmp.b #16,d0
  49.     bne.b tul2
  50. tul1    move.b d0,1(a7)
  51. tul2    pea 2+8(a7)
  52.     move.l 6+58+8+8(a7),-(a7)
  53.     move.l 6+58+8+8(a7),-(a7)
  54.     jsr _uvlongtostr
  55.     lea 14(a7),a7
  56.     move.l d0,4(a7)
  57.     jsr op__leftshift__ostream__TPCc
  58.     lea 50+8(a7),a7
  59.     move.l (a7)+,a0
  60.     move.l 4(a7),d0
  61.     rts
  62.  
  63.     end
  64.