View Source BitcoinLib.Script.Opcodes.FlowControl.EndIf (BitcoinLib v0.4.7)

Based on https://en.bitcoin.it/wiki/Script

Word OP_ENDIF Opcode 104 Hex 0x68

if [statements] [else [statements]]* endifEnds an if/else block. All blocks must end, or the transaction is invalid. An OP_ENDIF without OP_IF earlier is also invalid.

Link to this section Summary

Functions

Returns <<0x68>>

If the top stack value is not False, the statements are executed. The top stack value is removed.

v()

Returns 0x68

Link to this section Functions

@spec encode() :: <<_::8>>

Returns <<0x68>>

examples

Examples

iex> BitcoinLib.Script.Opcodes.FlowControl.EndIf.encode()
<<0x68>>

If the top stack value is not False, the statements are executed. The top stack value is removed.

@spec v() :: 104

Returns 0x68

examples

Examples

iex> BitcoinLib.Script.Opcodes.FlowControl.EndIf.v()
0x68