Module all
Expand description
Enables wildcard imports to bring into scope all opcodes and nothing else.
The all module is provided so one can use a wildcard import use bitcoin::opcodes::all::* to
get all the OP_FOO opcodes without getting other types defined in opcodes (e.g. All, Class).
This module is guaranteed to never contain anything except opcode constants and all opcode constants are guaranteed to begin with OP_.
Constants§
- OP_
0NOTEQUAL - Map 0 to 0 and everything else to 1, in place.
- OP_1ADD
- Increment the top stack element in place.
- OP_1SUB
- Decrement the top stack element in place.
- OP_2DIV
- Fail the script unconditionally, does not even need to be executed.
- OP_
2DROP - Drops the top two stack items.
- OP_2DUP
- Duplicates the top two stack items as AB -> ABAB.
- OP_2MUL
- Fail the script unconditionally, does not even need to be executed.
- OP_
2OVER - Copies the two stack items of items two spaces back to the front, as xxAB -> ABxxAB.
- OP_2ROT
- Moves the two stack items four spaces back to the front, as xxxxAB -> ABxxxx.
- OP_
2SWAP - Swaps the top two pairs, as ABCD -> CDAB.
- OP_3DUP
- Duplicates the two three stack items as ABC -> ABCABC.
- OP_ABS
- Absolute value the top stack item in place.
- OP_ADD
- Pop two stack items and push their sum.
- OP_AND
- Fail the script unconditionally, does not even need to be executed.
- OP_
BOOLAND - Pop the top two stack items and push 1 if both are nonzero, else push 0.
- OP_
BOOLOR - Pop the top two stack items and push 1 if either is nonzero, else push 0.
- OP_CAT
- Fail the script unconditionally, does not even need to be executed.
- OP_
CHECKMULTISIG - Pop N, N pubkeys, M, M signatures, a dummy (due to bug in reference code), and verify that all M signatures are valid. Push 1 for ‘all valid’, 0 otherwise.
- OP_
CHECKMULTISIGVERIFY - Like the above but return success/failure.
- OP_
CHECKSIG - https://en.bitcoin.it/wiki/OP_CHECKSIG pushing 1/0 for success/failure.
- OP_
CHECKSIGADD - OP_CHECKSIGADD post tapscript.
- OP_
CHECKSIGVERIFY - https://en.bitcoin.it/wiki/OP_CHECKSIG returning success/failure.
- OP_CLTV
- https://github.com/bitcoin/bips/blob/master/bip-0065.mediawiki
- OP_
CODESEPARATOR - Ignore this and everything preceding when deciding what to sign when signature-checking.
- OP_CSV
- https://github.com/bitcoin/bips/blob/master/bip-0112.mediawiki
- OP_
DEPTH - Push the current number of stack items onto the stack.
- OP_DIV
- Fail the script unconditionally, does not even need to be executed.
- OP_DROP
- Drops the top stack item.
- OP_DUP
- Duplicates the top stack item.
- OP_ELSE
- Execute statements if those after the previous OP_IF were not, and vice-versa. If there is no previous OP_IF, this acts as a RETURN.
- OP_
ENDIF - Pop and execute the next statements if a zero element was popped.
- OP_
EQUAL - Pushes 1 if the inputs are exactly equal, 0 otherwise.
- OP_
EQUALVERIFY - Returns success if the inputs are exactly equal, failure otherwise.
- OP_
FROMALTSTACK - Pop one element from the alt stack onto the main stack.
- OP_
GREATERTHAN - Pop the top two items; push 1 if the second is greater than the top, 0 otherwise.
- OP_
GREATERTHANOREQUAL - Pop the top two items; push 1 if the second is >= the top, 0 otherwise.
- OP_
HASH160 - Pop the top stack item and push its RIPEMD(SHA256) hash.
- OP_
HASH256 - Pop the top stack item and push its SHA256(SHA256) hash.
- OP_IF
- Pop and execute the next statements if a nonzero element was popped.
- OP_
IFDUP - Duplicate the top stack element unless it is zero.
- OP_
INVALIDOPCODE - Synonym for OP_RETURN.
- OP_
INVERT - Fail the script unconditionally, does not even need to be executed.
- OP_LEFT
- Fail the script unconditionally, does not even need to be executed.
- OP_
LESSTHAN - Pop the top two items; push 1 if the second is less than the top, 0 otherwise.
- OP_
LESSTHANOREQUAL - Pop the top two items; push 1 if the second is <= the top, 0 otherwise.
- OP_
LSHIFT - Fail the script unconditionally, does not even need to be executed.
- OP_MAX
- Pop the top two items; push the larger.
- OP_MIN
- Pop the top two items; push the smaller.
- OP_MOD
- Fail the script unconditionally, does not even need to be executed.
- OP_MUL
- Fail the script unconditionally, does not even need to be executed.
- OP_
NEGATE - Multiply the top stack item by -1 in place.
- OP_NIP
- Drops the second-to-top stack item.
- OP_NOP
- Does nothing.
- OP_NOP1
- Does nothing.
- OP_NOP4
- Does nothing.
- OP_NOP5
- Does nothing.
- OP_NOP6
- Does nothing.
- OP_NOP7
- Does nothing.
- OP_NOP8
- Does nothing.
- OP_NOP9
- Does nothing.
- OP_
NOP10 - Does nothing.
- OP_NOT
- Map 0 to 1 and everything else to 0, in place.
- OP_
NOTIF - Pop and execute the next statements if a zero element was popped.
- OP_
NUMEQUAL - Pop the top two stack items and push 1 if both are numerically equal, else push 0.
- OP_
NUMEQUALVERIFY - Pop the top two stack items and return success if both are numerically equal, else return failure.
- OP_
NUMNOTEQUAL - Pop the top two stack items and push 0 if both are numerically equal, else push 1.
- OP_OR
- Fail the script unconditionally, does not even need to be executed.
- OP_OVER
- Copies the second-to-top stack item, as xA -> AxA.
- OP_PICK
- Pop the top stack element as N. Copy the Nth stack element to the top.
- OP_
PUSHBYTES_ 0 - Push an empty array onto the stack.
- OP_
PUSHBYTES_ 1 - Push the next byte as an array onto the stack.
- OP_
PUSHBYTES_ 2 - Push the next 2 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 3 - Push the next 3 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 4 - Push the next 4 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 5 - Push the next 5 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 6 - Push the next 6 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 7 - Push the next 7 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 8 - Push the next 8 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 9 - Push the next 9 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 10 - Push the next 10 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 11 - Push the next 11 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 12 - Push the next 12 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 13 - Push the next 13 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 14 - Push the next 14 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 15 - Push the next 15 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 16 - Push the next 16 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 17 - Push the next 17 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 18 - Push the next 18 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 19 - Push the next 19 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 20 - Push the next 20 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 21 - Push the next 21 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 22 - Push the next 22 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 23 - Push the next 23 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 24 - Push the next 24 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 25 - Push the next 25 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 26 - Push the next 26 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 27 - Push the next 27 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 28 - Push the next 28 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 29 - Push the next 29 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 30 - Push the next 30 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 31 - Push the next 31 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 32 - Push the next 32 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 33 - Push the next 33 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 34 - Push the next 34 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 35 - Push the next 35 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 36 - Push the next 36 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 37 - Push the next 37 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 38 - Push the next 38 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 39 - Push the next 39 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 40 - Push the next 40 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 41 - Push the next 41 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 42 - Push the next 42 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 43 - Push the next 43 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 44 - Push the next 44 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 45 - Push the next 45 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 46 - Push the next 46 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 47 - Push the next 47 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 48 - Push the next 48 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 49 - Push the next 49 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 50 - Push the next 50 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 51 - Push the next 51 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 52 - Push the next 52 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 53 - Push the next 53 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 54 - Push the next 54 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 55 - Push the next 55 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 56 - Push the next 56 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 57 - Push the next 57 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 58 - Push the next 58 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 59 - Push the next 59 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 60 - Push the next 60 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 61 - Push the next 61 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 62 - Push the next 62 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 63 - Push the next 63 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 64 - Push the next 64 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 65 - Push the next 65 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 66 - Push the next 66 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 67 - Push the next 67 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 68 - Push the next 68 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 69 - Push the next 69 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 70 - Push the next 70 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 71 - Push the next 71 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 72 - Push the next 72 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 73 - Push the next 73 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 74 - Push the next 74 bytes as an array onto the stack.
- OP_
PUSHBYTES_ 75 - Push the next 75 bytes as an array onto the stack.
- OP_
PUSHDAT A1 - Read the next byte as N; push the next N bytes as an array onto the stack.
- OP_
PUSHDAT A2 - Read the next 2 bytes as N; push the next N bytes as an array onto the stack.
- OP_
PUSHDAT A4 - Read the next 4 bytes as N; push the next N bytes as an array onto the stack.
- OP_
PUSHNUM_ 1 - Push the array
0x01onto the stack. - OP_
PUSHNUM_ 2 - the array
0x02onto the stack. - OP_
PUSHNUM_ 3 - Push the array
0x03onto the stack. - OP_
PUSHNUM_ 4 - Push the array
0x04onto the stack. - OP_
PUSHNUM_ 5 - Push the array
0x05onto the stack. - OP_
PUSHNUM_ 6 - Push the array
0x06onto the stack. - OP_
PUSHNUM_ 7 - Push the array
0x07onto the stack. - OP_
PUSHNUM_ 8 - Push the array
0x08onto the stack. - OP_
PUSHNUM_ 9 - Push the array
0x09onto the stack. - OP_
PUSHNUM_ 10 - Push the array
0x0aonto the stack. - OP_
PUSHNUM_ 11 - Push the array
0x0bonto the stack. - OP_
PUSHNUM_ 12 - Push the array
0x0conto the stack. - OP_
PUSHNUM_ 13 - Push the array
0x0donto the stack. - OP_
PUSHNUM_ 14 - Push the array
0x0eonto the stack. - OP_
PUSHNUM_ 15 - Push the array
0x0fonto the stack. - OP_
PUSHNUM_ 16 - Push the array
0x10onto the stack. - OP_
PUSHNUM_ NEG1 - Push the array
0x81onto the stack. - OP_
RESERVED - Synonym for OP_RETURN.
- OP_
RESERVE D1 - Synonym for OP_RETURN.
- OP_
RESERVE D2 - Synonym for OP_RETURN.
- OP_
RETURN - Fail the script immediately. (Must be executed.).
- OP_
RETURN_ 187 - Synonym for OP_RETURN.
- OP_
RETURN_ 188 - Synonym for OP_RETURN.
- OP_
RETURN_ 189 - Synonym for OP_RETURN.
- OP_
RETURN_ 190 - Synonym for OP_RETURN.
- OP_
RETURN_ 191 - Synonym for OP_RETURN.
- OP_
RETURN_ 192 - Synonym for OP_RETURN.
- OP_
RETURN_ 193 - Synonym for OP_RETURN.
- OP_
RETURN_ 194 - Synonym for OP_RETURN.
- OP_
RETURN_ 195 - Synonym for OP_RETURN.
- OP_
RETURN_ 196 - Synonym for OP_RETURN.
- OP_
RETURN_ 197 - Synonym for OP_RETURN.
- OP_
RETURN_ 198 - Synonym for OP_RETURN.
- OP_
RETURN_ 199 - Synonym for OP_RETURN.
- OP_
RETURN_ 200 - Synonym for OP_RETURN.
- OP_
RETURN_ 201 - Synonym for OP_RETURN.
- OP_
RETURN_ 202 - Synonym for OP_RETURN.
- OP_
RETURN_ 203 - Synonym for OP_RETURN.
- OP_
RETURN_ 204 - Synonym for OP_RETURN.
- OP_
RETURN_ 205 - Synonym for OP_RETURN.
- OP_
RETURN_ 206 - Synonym for OP_RETURN.
- OP_
RETURN_ 207 - Synonym for OP_RETURN.
- OP_
RETURN_ 208 - Synonym for OP_RETURN.
- OP_
RETURN_ 209 - Synonym for OP_RETURN.
- OP_
RETURN_ 210 - Synonym for OP_RETURN.
- OP_
RETURN_ 211 - Synonym for OP_RETURN.
- OP_
RETURN_ 212 - Synonym for OP_RETURN.
- OP_
RETURN_ 213 - Synonym for OP_RETURN.
- OP_
RETURN_ 214 - Synonym for OP_RETURN.
- OP_
RETURN_ 215 - Synonym for OP_RETURN.
- OP_
RETURN_ 216 - Synonym for OP_RETURN.
- OP_
RETURN_ 217 - Synonym for OP_RETURN.
- OP_
RETURN_ 218 - Synonym for OP_RETURN.
- OP_
RETURN_ 219 - Synonym for OP_RETURN.
- OP_
RETURN_ 220 - Synonym for OP_RETURN.
- OP_
RETURN_ 221 - Synonym for OP_RETURN.
- OP_
RETURN_ 222 - Synonym for OP_RETURN.
- OP_
RETURN_ 223 - Synonym for OP_RETURN.
- OP_
RETURN_ 224 - Synonym for OP_RETURN.
- OP_
RETURN_ 225 - Synonym for OP_RETURN.
- OP_
RETURN_ 226 - Synonym for OP_RETURN.
- OP_
RETURN_ 227 - Synonym for OP_RETURN.
- OP_
RETURN_ 228 - Synonym for OP_RETURN.
- OP_
RETURN_ 229 - Synonym for OP_RETURN.
- OP_
RETURN_ 230 - Synonym for OP_RETURN.
- OP_
RETURN_ 231 - Synonym for OP_RETURN.
- OP_
RETURN_ 232 - Synonym for OP_RETURN.
- OP_
RETURN_ 233 - Synonym for OP_RETURN.
- OP_
RETURN_ 234 - Synonym for OP_RETURN.
- OP_
RETURN_ 235 - Synonym for OP_RETURN.
- OP_
RETURN_ 236 - Synonym for OP_RETURN.
- OP_
RETURN_ 237 - Synonym for OP_RETURN.
- OP_
RETURN_ 238 - Synonym for OP_RETURN.
- OP_
RETURN_ 239 - Synonym for OP_RETURN.
- OP_
RETURN_ 240 - Synonym for OP_RETURN.
- OP_
RETURN_ 241 - Synonym for OP_RETURN.
- OP_
RETURN_ 242 - Synonym for OP_RETURN.
- OP_
RETURN_ 243 - Synonym for OP_RETURN.
- OP_
RETURN_ 244 - Synonym for OP_RETURN.
- OP_
RETURN_ 245 - Synonym for OP_RETURN.
- OP_
RETURN_ 246 - Synonym for OP_RETURN.
- OP_
RETURN_ 247 - Synonym for OP_RETURN.
- OP_
RETURN_ 248 - Synonym for OP_RETURN.
- OP_
RETURN_ 249 - Synonym for OP_RETURN.
- OP_
RETURN_ 250 - Synonym for OP_RETURN.
- OP_
RETURN_ 251 - Synonym for OP_RETURN.
- OP_
RETURN_ 252 - Synonym for OP_RETURN.
- OP_
RETURN_ 253 - Synonym for OP_RETURN.
- OP_
RETURN_ 254 - Synonym for OP_RETURN.
- OP_
RIGHT - Fail the script unconditionally, does not even need to be executed.
- OP_
RIPEM D160 - Pop the top stack item and push its RIPEMD160 hash.
- OP_ROLL
- Pop the top stack element as N. Move the Nth stack element to the top.
- OP_ROT
- Rotate the top three stack items, as [top next1 next2] -> [next2 top next1].
- OP_
RSHIFT - Fail the script unconditionally, does not even need to be executed.
- OP_SHA1
- Pop the top stack item and push its SHA1 hash.
- OP_
SHA256 - Pop the top stack item and push its SHA256 hash.
- OP_SIZE
- Pushes the length of the top stack item onto the stack.
- OP_SUB
- Pop two stack items and push the second minus the top.
- OP_
SUBSTR - Fail the script unconditionally, does not even need to be executed.
- OP_SWAP
- Swap the top two stack items.
- OP_
TOALTSTACK - Pop one element from the main stack onto the alt stack.
- OP_TUCK
- Copy the top stack item to before the second item, as [top next] -> [top next top].
- OP_VER
- Synonym for OP_RETURN.
- OP_
VERIF - Fail the script unconditionally, does not even need to be executed.
- OP_
VERIFY - If the top value is zero or the stack is empty, fail; otherwise, pop the stack.
- OP_
VERNOTIF - Fail the script unconditionally, does not even need to be executed.
- OP_
WITHIN - Pop the top three items; if the top is >= the second and < the third, push 1, otherwise push 0.
- OP_XOR
- Fail the script unconditionally, does not even need to be executed.