GOSUB / SUB Enhancement

hippy

Technical Support
Staff member
Would it be possible to add a SUB command to define a named label and a list of variables to be pre-loaded when called ? With SUB as a block-statement ( like IF-ENDIF and DO-LOOP ) block structured subroutines, with END SUB being a RETURN would be very nice ...<code><pre><font size=2 face='Courier'>Call Print(1,b0)
Call Print(0,65536)
End </font></pre></code> <code><pre><font size=2 face='Courier'>Sub Print(b11,w6)
SerOut b11,N2400,(#w6,CR,LF)
End Sub </font></pre></code> Would be compiled as if it were ...<code><pre><font size=2 face='Courier'>b11 = 1 : w6 = b0 : Gosub Print
b11 = 0 : w6 = 65535 : Gosub Print
End </font></pre></code> <code><pre><font size=2 face='Courier'>Print:
SerOut b11,N2400,(#w6,CR,LF)
Return </font></pre></code>
 
Top