retint


* Do whats necessary to return int to S*Basic
* ©pjwitte 2oo6
*

        section code

        xdef retint

        xref resrir

        include dev8_keys_sbasic

*
retint
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Reserve room and return integer to S*Basic
* input :
*       d4.l = return value
*       stack must be in a tidy ("empty") state prior to this call
*
* return: cc = set
*       errors: returns directly to BASIC with d0 = 0 (Qdos) or OM (Smsq/e)
*
        moveq #2,d1             two bytes required
        bsr resrir              reserve and create space

        move.w d4,0(a6,a1.l)

        moveq #ar.int,d4        return code = integer
        moveq #0,d0
        rts

*
        end

Back to Index
HTML generated by the amazing asm2htm !
2006 Sep 30 16:54:46