% $RCSfile: StackSecureStateBun.oz,v $ declare fun {NewStack} C={NewCell nil} proc {Push E} C:=E|@C end fun {Pop} case @C of X|S1 then C:=S1 X end end fun {IsEmpty} @C==nil end in stack(push:Push pop:Pop isEmpty:IsEmpty) end