Recent Changes - Search:
Email with comments and/or suggestions.

Aibo General

Aibo Development

Wiki Help

Aibo Links

R-Code » CALL

CALL Statement

Executes a subroutine. Subroutine arguments are passed by placing them on the stack before a CALL using the PUSH statement.


ERS-210 ERS-220 ERS-31x ERS-7



The CALL statement syntax has the following parts:

labelThe user defined label to call as a subroutine.
argcOpional. Count of arguments placed on the stack with PUSH.


   CALL:sub1   // equivalent to: sub1()

   PUSH:10     // argument 1
   PUSH:20     // argument 2
   PUSH:30     // argument 3
   CALL:sub2:3 // equivalent to: sub2(10, 20, 30)


On calling a subroutine, the current Context value is automatically placed onto the stack and is automatically restored when a RETURN statement brings the program back from the subroutine call.

Edit - History - Print - Recent Changes - Search - Site Terms of Use
Page last modified on February 07, 2006, at 09:27 PM CST