        $MACRO ELSEIF ...
;get nos
?+ 17,2
        JMP #@H
?+ 15
        #@F=.
?+ 16
        IF <#@*(1"Z)>
?- #@H,2
            $ENDM
            $MACRO ALL VAR
            JSR PC,$$RES
            RES.STR #@{1} @#$$RES1
            $ENDM
; - - - - - - - - - - - - - - - - - - - - - - -
            $MACRO FRE
            MOV (SP),R0
            ADD R0,SP
            $ENDM
; - - - - - - - - - - - - - - - - - - - - - - -
            $MACRO RES.STR ;  NAME,SIZE
            SUB #@2,SP
            SUB #10.,SP
            MOV #1,-(SP)
            MOV #@2,-(SP)
            ADD #8.,(SP)
            MOV SP,#@1
            MOV #@1,-(SP)
            JSR PC,INI
            ADD #6.,(SP)
            JSR PC,$$$STK
            $ENDM
; - - - - - - - - - - - - - - - - - - - - - - -
            $MACRO print
            ** p%%t <#@*(1"Z)>
            $ENDM
; - - - - - - - - - - - - - - - - - - - - - - -
            $MACRO p%%t
            printf "#@1=(%d)(%o)" <#@1> <#@1>
            $ENDM
; - - - - - - - - - - - - - - - - - - - - - - -
            $MACRO LEN string
?? 2
            mov #@{1},r0
            #@2=.
            tstb (r0)+
            bne #@2
            sub #@{1},r0
            dec r0
            $ENDM
            $MACRO SMP
            .WORD 100.,20.,0,0,0,0
            ** SMPX <#@*(1"Z)>
            .EVEN
            $ENDM
            $MACRO SMPX
            S%LEN <#@1> 9
            .BYTE #@#9.
            .ASCII _#@1_
            $ENDM
/
            program stat3	;check for assignment or function calls
x1:         .asciz 'LETA <#@*(0"Z)>'
x2:         .asciz 'LET <#@*(0"Z)>'
x3:         .asciz 'C r0 = <#@0>'
x4:         .asciz '	#@0 #@{1},#@{2}'
x5:         .asciz '	#@0 #@{1}'
            .even
strs:       smp := =	;an = or := is assignment op

            optimize using r2

            auto prm

            function assign[s,t,n,l,labout]
            let prm = l * -1

  if ifnstr[2,#strs,fndstr[t,<prm + 2>]] ne 0 and n ge <prm + 3>
                call ifrr
                if r4 ne 0 ;recursive if ne 0
                    mov #x1,r4
                    call out
                else
                    mov #x2,r4
                    call out
                fi

            else
                call ifrr
                if r4 ne 0
                    mov #x3,r4
                    call out
                else
                    let r4 = fndstr[t,<prm + 1>]
                    ifb 1(r4) = #'.
                        . outst[s]
                    else
                        if n = <prm + 3>	;just three args
                            mov #x4,r4
                            call out

                        elseif n = <prm + 2>    ;just two arg
                            mov #x5,r4
                            call out
                        else
                            . outst[s]
                        fi
                    fi
                fi
            fi
done:
            ret
ifrr:
            let r4 =  ifrec1[fndstr[t,<prm + 1>]]
            rts pc
out:
            if l ne 0 and labout = 0
                . outst[t]
            fi
            . exstate[r4,&s,0]
            rts pc
            .end
