2.5.3.1.10 PopStack

A support function, PopStack, pops the topmost operand from the stack.

 STACKELEMENT
 PopStack (
       STACK ResultStack,
       INT32 StackPos
    )
     --
     -- On entry
     --    ResultStack is the stack.
     --    StackPos is the stack position
  
     IF StackPos equals 0 THEN
        Return NULL
     END IF
  
     Decrement StackPos by 1
     Return ResultStack[StackPos]
 END-SUBROUTINE
Show: