;-----------------------------------------------------------
; sasglue.a
;
;    This is the actual dispatch routine that will be called.
;    It pushes arguments on the stack and then calls our C
;    dispatch function, storing the result string in A0.  Link
;    this with libent.a and the C code for the library.
;
	section	code

    xref     ARLibDispatch

LIBDispatch:
	movem.l	 d2/d3/d4-d7/a2-a6,-(sp)

	subq.l   #4,sp			; Create temporary variable
	move.l   sp,-(sp)		; Push return pointer
	move.l   a0,-(sp)		; Push argument
	jsr      ARLibDispatch		; D0 = error code
	addq.l   #8,sp			; Restore stack
	movea.l  (sp)+,a0		; Result string

	movem.l	 (sp)+,d2/d3/d4-d7/a2-a6
	rts

	xdef     LIBDispatch

	end
