Try it Live
Run Opcode examples in the interactive playground
Opcode.dupPosition()
Get stack position duplicated by DUP opcode (1-16).- Functional API
Parameters
opcode: BrandedOpcode- Opcode to check
Returns
number | undefined - Position (1-16) or undefined if not DUP
Stack Semantics
Related
- isDup() - Check if DUP opcode

