Show pageDiscussionOld revisionsBacklinksBack to top This page is read only. You can view the source, but not change it. Ask your administrator if you think this is wrong. ==== STKPUSH ==== ---- <callout type="primary" color="" icon="fa fa-book" title="Synopsis"> ---- Push a snapshot of the current stack on the Undo stack </callout> <callout color="green" icon="fa fa-indent" title="Stack Diagram"> ---- ^ __Input Stack__ ^ ^ __Output Stack__ ^ | | **→** | | | //Level 1// | //→// | //Level 1// | {{page>manual:chapter6:aux:legend&nofooter&noeditbtn&inline}} |**Type**| [[manual:chapter5:basics#commands|Command]] || |**Parallel list processing**| [[manual:chapter5:listproc#group-1commands-that-cannot-parallel-process|Group 1]] || |**Affected by flags**| None || </callout> <callout color="orangered" icon="fa fa-comment" title="Description"> ---- The ''STKPUSH'' command creates a snapshot of the stack and pushes it on the top of the Undo stack. The Undo stack may contain up to 8 snapshots: each time a ninth is pushed on it, the snapshot on level 8 is lost. The command has little utility in interactive mode, since each time a command is typed and ''[[manual:chapter6:operators:cmd_ovr_xeq|XEQ]]''ted a snapshot of the stack is already pushed on the Undo stack: the only effect of ''STKPUSH'' would be to duplicate the latest snapshot. </callout> <callout type="danger" icon="true" title="Compatibility"> ---- This command is new in newRPL and does not exist in userRPL. </callout> <callout type="info" icon="true" title="Usage"> ---- The following program <code> « 123 456 789 STKPUSH CLEAR » </code> leaves an empty stack. If **LF** is pressed, the previous stack will be restored. <code> 3: 123 2: 456 1: 789 …………………………………………………………………………………… </code> </callout> <callout color="darkgray" icon="fa fa-hand-o-right" title="Related Commands"> ---- {{page>manual:chapter6:stack&nofooter&noeditbtn&inline}} </callout> manual/chapter6/stack/cmd_stkpush.txt Last modified: 2019/10/22 15:22by jojo1973