1
DUP2_X1
Nunuhara Cabbage edited this page 2019-11-05 18:05:19 -08:00

DUP2_X1

Instruction Arguments

None.

Stack Arguments

int32 value1 - The first value to duplicate
int32 value2 - The second value to duplicate

Description

Duplicate the top two values on the stack, splicing them in one space back.

Example

PUSH 0x1 ; stack: [1]
PUSH 0x2 ; stack: [1, 2]
PUSH 0x3 ; stack: [1, 2, 3]
DUP2_X1  ; stack: [2, 3, 1, 2, 3]