Skip to content

wake.ir.enums module #

AssignmentOperator class #

Bases: StrEnum

Assignment operator used in an Assignment expression.

Source code in wake/ir/enums.py
class AssignmentOperator(StrEnum):
    """
    Assignment operator used in an [Assignment][wake.ir.expressions.assignment.Assignment] expression.
    """

    EQUALS = r"="
    PLUS_EQUALS = r"+="
    MINUS_EQUALS = r"-="
    TIMES_EQUALS = r"*="
    DIVIDE_EQUALS = r"/="
    MODULO_EQUALS = r"%="
    OR_EQUALS = r"|="
    AND_EQUALS = r"&="
    XOR_EQUALS = r"^="
    RIGHT_SHIFT_EQUALS = r">>="
    LEFT_SHIFT_EQUALS = r"<<="

AND_EQUALS = '&=' class-attribute instance-attribute #

DIVIDE_EQUALS = '/=' class-attribute instance-attribute #

EQUALS = '=' class-attribute instance-attribute #

LEFT_SHIFT_EQUALS = '<<=' class-attribute instance-attribute #

MINUS_EQUALS = '-=' class-attribute instance-attribute #

MODULO_EQUALS = '%=' class-attribute instance-attribute #

OR_EQUALS = '|=' class-attribute instance-attribute #

PLUS_EQUALS = '+=' class-attribute instance-attribute #

RIGHT_SHIFT_EQUALS = '>>=' class-attribute instance-attribute #

TIMES_EQUALS = '*=' class-attribute instance-attribute #

XOR_EQUALS = '^=' class-attribute instance-attribute #

BinaryOpOperator class #

Bases: StrEnum

Binary operation operator used in a BinaryOperation expression.

Source code in wake/ir/enums.py
class BinaryOpOperator(StrEnum):
    """
    Binary operation operator used in a [BinaryOperation][wake.ir.expressions.binary_operation.BinaryOperation] expression.
    """

    PLUS = r"+"
    MINUS = r"-"
    TIMES = r"*"
    DIVIDE = r"/"
    MODULO = r"%"
    EXP = r"**"
    BOOLEAN_AND = r"&&"
    BOOLEAN_OR = r"||"
    NEQ = r"!="
    EQ = r"=="
    LT = r"<"
    LTE = r"<="
    GT = r">"
    GTE = r">="
    XOR = r"^"
    BITWISE_AND = r"&"
    BITWISE_OR = r"|"
    LEFT_SHIFT = r"<<"
    RIGHT_SHIFT = r">>"

BITWISE_AND = '&' class-attribute instance-attribute #

BITWISE_OR = '|' class-attribute instance-attribute #

BOOLEAN_AND = '&&' class-attribute instance-attribute #

BOOLEAN_OR = '||' class-attribute instance-attribute #

DIVIDE = '/' class-attribute instance-attribute #

EQ = '==' class-attribute instance-attribute #

EXP = '**' class-attribute instance-attribute #

GT = '>' class-attribute instance-attribute #

GTE = '>=' class-attribute instance-attribute #

LEFT_SHIFT = '<<' class-attribute instance-attribute #

LT = '<' class-attribute instance-attribute #

LTE = '<=' class-attribute instance-attribute #

MINUS = '-' class-attribute instance-attribute #

MODULO = '%' class-attribute instance-attribute #

NEQ = '!=' class-attribute instance-attribute #

PLUS = '+' class-attribute instance-attribute #

RIGHT_SHIFT = '>>' class-attribute instance-attribute #

TIMES = '*' class-attribute instance-attribute #

XOR = '^' class-attribute instance-attribute #

ContractKind class #

Bases: StrEnum

Kind of a ContractDefinition declaration node.

Source code in wake/ir/enums.py
class ContractKind(StrEnum):
    """
    Kind of a [ContractDefinition][wake.ir.declarations.contract_definition.ContractDefinition] declaration node.
    """

    CONTRACT = "contract"
    INTERFACE = "interface"
    LIBRARY = "library"

CONTRACT = 'contract' class-attribute instance-attribute #

INTERFACE = 'interface' class-attribute instance-attribute #

LIBRARY = 'library' class-attribute instance-attribute #

DataLocation class #

Bases: StrEnum

Data location of a VariableDeclaration node. It also specifies the data location of the following types:

Source code in wake/ir/enums.py
class DataLocation(StrEnum):
    """
    Data location of a [VariableDeclaration][wake.ir.declarations.variable_declaration.VariableDeclaration] node.
    It also specifies the data location of the following types:

    - [Array][wake.ir.types.Array],
    - [Bytes][wake.ir.types.Bytes],
    - [String][wake.ir.types.String],
    - [Struct][wake.ir.types.Struct].
    """

    CALLDATA = "calldata"
    DEFAULT = "default"
    """
    Set only in [VariableDeclaration][wake.ir.declarations.variable_declaration.VariableDeclaration] nodes when the data location is not specified (and the compiler even does not allow it).
    """
    MEMORY = "memory"
    STORAGE = "storage"
    TRANSIENT = "transient"

CALLDATA = 'calldata' class-attribute instance-attribute #

DEFAULT = 'default' class-attribute instance-attribute #

Set only in VariableDeclaration nodes when the data location is not specified (and the compiler even does not allow it).

MEMORY = 'memory' class-attribute instance-attribute #

STORAGE = 'storage' class-attribute instance-attribute #

TRANSIENT = 'transient' class-attribute instance-attribute #

FunctionCallKind class #

Bases: StrEnum

Kind of a FunctionCall expression node.

Source code in wake/ir/enums.py
class FunctionCallKind(StrEnum):
    """
    Kind of a [FunctionCall][wake.ir.expressions.function_call.FunctionCall] expression node.
    """

    FUNCTION_CALL = "functionCall"
    """
    Represents also an error call, event call and [NewExpression][wake.ir.expressions.new_expression.NewExpression] call.
    """
    TYPE_CONVERSION = "typeConversion"
    STRUCT_CONSTRUCTOR_CALL = "structConstructorCall"

FUNCTION_CALL = 'functionCall' class-attribute instance-attribute #

Represents also an error call, event call and NewExpression call.

STRUCT_CONSTRUCTOR_CALL = 'structConstructorCall' class-attribute instance-attribute #

TYPE_CONVERSION = 'typeConversion' class-attribute instance-attribute #

FunctionKind class #

Bases: StrEnum

Kind of a FunctionDefinition declaration node.

Source code in wake/ir/enums.py
class FunctionKind(StrEnum):
    """
    Kind of a [FunctionDefinition][wake.ir.declarations.function_definition.FunctionDefinition] declaration node.
    """

    FUNCTION = "function"
    RECEIVE = "receive"
    CONSTRUCTOR = "constructor"
    FALLBACK = "fallback"
    FREE_FUNCTION = "freeFunction"
    """
    Function defined outside of a contract.
    """

CONSTRUCTOR = 'constructor' class-attribute instance-attribute #

FALLBACK = 'fallback' class-attribute instance-attribute #

FREE_FUNCTION = 'freeFunction' class-attribute instance-attribute #

Function defined outside of a contract.

FUNCTION = 'function' class-attribute instance-attribute #

RECEIVE = 'receive' class-attribute instance-attribute #

FunctionTypeKind class #

Bases: StrEnum

Kind of a Function type.

Source code in wake/ir/enums.py
class FunctionTypeKind(StrEnum):
    """
    Kind of a [Function][wake.ir.types.Function] type.
    """

    DECLARATION = "declaration"
    INTERNAL = "internal"
    EXTERNAL = "external"
    DELEGATE_CALL = "delegatecall"
    BARE_CALL = "barecall"
    BARE_CALL_CODE = "barecallcode"
    BARE_DELEGATE_CALL = "baredelegatecall"
    BARE_STATIC_CALL = "barestaticcall"
    CREATION = "creation"
    SEND = "send"
    TRANSFER = "transfer"
    KECCAK256 = "keccak256"
    SELFDESTRUCT = "selfdestruct"
    REVERT = "revert"
    EC_RECOVER = "ecrecover"
    SHA256 = "sha256"
    RIPEMD160 = "ripemd160"
    LOG0 = "log0"
    LOG1 = "log1"
    LOG2 = "log2"
    LOG3 = "log3"
    LOG4 = "log4"
    GAS_LEFT = "gasleft"
    EVENT = "event"
    ERROR = "error"
    WRAP = "wrap"
    UNWRAP = "unwrap"
    SET_GAS = "setgas"
    SET_VALUE = "setvalue"
    BLOCK_HASH = "blockhash"
    BLOBHASH = "blobhash"
    ADD_MOD = "addmod"
    MUL_MOD = "mulmod"
    ARRAY_PUSH = "arraypush"
    ARRAY_POP = "arraypop"  # TODO also used for byte array pop, distinguish?
    BYTE_ARRAY_PUSH = "bytearraypush"
    BYTES_CONCAT = "bytesconcat"
    STRING_CONCAT = "stringconcat"
    OBJECT_CREATION = "objectcreation"
    ASSERT = "assert"
    REQUIRE = "require"
    ABI_ENCODE = "abiencode"
    ABI_ENCODE_PACKED = "abiencodepacked"
    ABI_ENCODE_WITH_SELECTOR = "abiencodewithselector"
    ABI_ENCODE_CALL = "abiencodecall"
    ABI_ENCODE_WITH_SIGNATURE = "abiencodewithsignature"
    ABI_DECODE = "abidecode"
    META_TYPE = "metatype"

ABI_DECODE = 'abidecode' class-attribute instance-attribute #

ABI_ENCODE = 'abiencode' class-attribute instance-attribute #

ABI_ENCODE_CALL = 'abiencodecall' class-attribute instance-attribute #

ABI_ENCODE_PACKED = 'abiencodepacked' class-attribute instance-attribute #

ABI_ENCODE_WITH_SELECTOR = 'abiencodewithselector' class-attribute instance-attribute #

ABI_ENCODE_WITH_SIGNATURE = 'abiencodewithsignature' class-attribute instance-attribute #

ADD_MOD = 'addmod' class-attribute instance-attribute #

ARRAY_POP = 'arraypop' class-attribute instance-attribute #

ARRAY_PUSH = 'arraypush' class-attribute instance-attribute #

ASSERT = 'assert' class-attribute instance-attribute #

BARE_CALL = 'barecall' class-attribute instance-attribute #

BARE_CALL_CODE = 'barecallcode' class-attribute instance-attribute #

BARE_DELEGATE_CALL = 'baredelegatecall' class-attribute instance-attribute #

BARE_STATIC_CALL = 'barestaticcall' class-attribute instance-attribute #

BLOBHASH = 'blobhash' class-attribute instance-attribute #

BLOCK_HASH = 'blockhash' class-attribute instance-attribute #

BYTES_CONCAT = 'bytesconcat' class-attribute instance-attribute #

BYTE_ARRAY_PUSH = 'bytearraypush' class-attribute instance-attribute #

CREATION = 'creation' class-attribute instance-attribute #

DECLARATION = 'declaration' class-attribute instance-attribute #

DELEGATE_CALL = 'delegatecall' class-attribute instance-attribute #

EC_RECOVER = 'ecrecover' class-attribute instance-attribute #

ERROR = 'error' class-attribute instance-attribute #

EVENT = 'event' class-attribute instance-attribute #

EXTERNAL = 'external' class-attribute instance-attribute #

GAS_LEFT = 'gasleft' class-attribute instance-attribute #

INTERNAL = 'internal' class-attribute instance-attribute #

KECCAK256 = 'keccak256' class-attribute instance-attribute #

LOG0 = 'log0' class-attribute instance-attribute #

LOG1 = 'log1' class-attribute instance-attribute #

LOG2 = 'log2' class-attribute instance-attribute #

LOG3 = 'log3' class-attribute instance-attribute #

LOG4 = 'log4' class-attribute instance-attribute #

META_TYPE = 'metatype' class-attribute instance-attribute #

MUL_MOD = 'mulmod' class-attribute instance-attribute #

OBJECT_CREATION = 'objectcreation' class-attribute instance-attribute #

REQUIRE = 'require' class-attribute instance-attribute #

REVERT = 'revert' class-attribute instance-attribute #

RIPEMD160 = 'ripemd160' class-attribute instance-attribute #

SELFDESTRUCT = 'selfdestruct' class-attribute instance-attribute #

SEND = 'send' class-attribute instance-attribute #

SET_GAS = 'setgas' class-attribute instance-attribute #

SET_VALUE = 'setvalue' class-attribute instance-attribute #

SHA256 = 'sha256' class-attribute instance-attribute #

STRING_CONCAT = 'stringconcat' class-attribute instance-attribute #

TRANSFER = 'transfer' class-attribute instance-attribute #

UNWRAP = 'unwrap' class-attribute instance-attribute #

WRAP = 'wrap' class-attribute instance-attribute #

GlobalSymbol class #

Bases: IntEnum

Global symbols of the Solidity language. Symbols with identifiers from -1 to -99 are codified by the compiler and can only be referenced by Identifier nodes. Other symbols are not officially codified by the compiler, but Wake also defines identifiers for them. These symbols can only be referenced by MemberAccess nodes. See the Solidity docs for (an incomplete) list of global symbols and their descriptions.

Source code in wake/ir/enums.py
class GlobalSymbol(IntEnum):
    """
    Global symbols of the Solidity language. Symbols with identifiers from `-1` to `-99` are codified by the compiler and can only be referenced by [Identifier][wake.ir.expressions.identifier.Identifier] nodes.
    Other symbols are not officially codified by the compiler, but Wake also defines identifiers for them. These symbols can only be referenced by [MemberAccess][wake.ir.expressions.member_access.MemberAccess] nodes.
    See the [Solidity docs](https://docs.soliditylang.org/en/latest/units-and-global-variables.html#special-variables-and-functions) for (an incomplete) list of global symbols and their descriptions.
    """

    ABI = -1
    ADDMOD = -2
    ASSERT = -3
    BLOCK = -4
    BLOCKHASH = -5
    ECRECOVER = -6
    GASLEFT = -7
    KECCAK256 = -8
    LOG0 = -10  # removed in Solidity 0.8.0
    LOG1 = -11  # removed in Solidity 0.8.0
    LOG2 = -12  # removed in Solidity 0.8.0
    LOG3 = -13  # removed in Solidity 0.8.0
    LOG4 = -14  # removed in Solidity 0.8.0
    MSG = -15
    MULMOD = -16
    NOW = -17
    REQUIRE = -18
    REVERT = -19
    RIPEMD160 = -20
    SELFDESTRUCT = -21
    SHA256 = -22
    SHA3 = -23
    SUICIDE = -24
    SUPER = -25
    TX = -26
    TYPE = -27
    THIS = -28
    BLOBHASH = -29

    BLOCK_BASEFEE = -100
    BLOCK_CHAINID = -101
    BLOCK_COINBASE = -102
    BLOCK_DIFFICULTY = -103
    BLOCK_GASLIMIT = -104
    BLOCK_NUMBER = -105
    BLOCK_TIMESTAMP = -106
    BLOCK_PREVRANDAO = -107
    BLOCK_BLOBBASEFEE = -108

    MSG_DATA = -200
    MSG_SENDER = -201
    MSG_SIG = -202
    MSG_VALUE = -203

    TX_GASPRICE = -300
    TX_ORIGIN = -301

    ABI_DECODE = -400
    ABI_ENCODE = -401
    ABI_ENCODE_PACKED = -402
    ABI_ENCODE_WITH_SELECTOR = -403
    ABI_ENCODE_WITH_SIGNATURE = -404
    ABI_ENCODE_CALL = -405

    BYTES_CONCAT = -500
    BYTES_LENGTH = -501
    BYTES_PUSH = -502
    BYTES_POP = -503

    STRING_CONCAT = -600

    ADDRESS_BALANCE = -700
    ADDRESS_CODE = -701
    ADDRESS_CODEHASH = -702
    ADDRESS_TRANSFER = -703
    ADDRESS_SEND = -704
    ADDRESS_CALL = -705
    ADDRESS_DELEGATECALL = -706
    ADDRESS_STATICCALL = -707

    # available for contracts and interfaces
    TYPE_NAME = -800
    TYPE_CREATION_CODE = -801
    TYPE_RUNTIME_CODE = -802
    # available for interfaces only
    TYPE_INTERFACE_ID = -803
    # available for integers
    TYPE_MIN = -804
    TYPE_MAX = -805

    ARRAY_LENGTH = -900
    ARRAY_PUSH = -901
    ARRAY_POP = -902

    FUNCTION_SELECTOR = -1000
    FUNCTION_VALUE = -1001
    FUNCTION_GAS = -1002
    FUNCTION_ADDRESS = -1003

    USER_DEFINED_VALUE_TYPE_WRAP = -1100
    USER_DEFINED_VALUE_TYPE_UNWRAP = -1101

ABI = -1 class-attribute instance-attribute #

ABI_DECODE = -400 class-attribute instance-attribute #

ABI_ENCODE = -401 class-attribute instance-attribute #

ABI_ENCODE_CALL = -405 class-attribute instance-attribute #

ABI_ENCODE_PACKED = -402 class-attribute instance-attribute #

ABI_ENCODE_WITH_SELECTOR = -403 class-attribute instance-attribute #

ABI_ENCODE_WITH_SIGNATURE = -404 class-attribute instance-attribute #

ADDMOD = -2 class-attribute instance-attribute #

ADDRESS_BALANCE = -700 class-attribute instance-attribute #

ADDRESS_CALL = -705 class-attribute instance-attribute #

ADDRESS_CODE = -701 class-attribute instance-attribute #

ADDRESS_CODEHASH = -702 class-attribute instance-attribute #

ADDRESS_DELEGATECALL = -706 class-attribute instance-attribute #

ADDRESS_SEND = -704 class-attribute instance-attribute #

ADDRESS_STATICCALL = -707 class-attribute instance-attribute #

ADDRESS_TRANSFER = -703 class-attribute instance-attribute #

ARRAY_LENGTH = -900 class-attribute instance-attribute #

ARRAY_POP = -902 class-attribute instance-attribute #

ARRAY_PUSH = -901 class-attribute instance-attribute #

ASSERT = -3 class-attribute instance-attribute #

BLOBHASH = -29 class-attribute instance-attribute #

BLOCK = -4 class-attribute instance-attribute #

BLOCKHASH = -5 class-attribute instance-attribute #

BLOCK_BASEFEE = -100 class-attribute instance-attribute #

BLOCK_BLOBBASEFEE = -108 class-attribute instance-attribute #

BLOCK_CHAINID = -101 class-attribute instance-attribute #

BLOCK_COINBASE = -102 class-attribute instance-attribute #

BLOCK_DIFFICULTY = -103 class-attribute instance-attribute #

BLOCK_GASLIMIT = -104 class-attribute instance-attribute #

BLOCK_NUMBER = -105 class-attribute instance-attribute #

BLOCK_PREVRANDAO = -107 class-attribute instance-attribute #

BLOCK_TIMESTAMP = -106 class-attribute instance-attribute #

BYTES_CONCAT = -500 class-attribute instance-attribute #

BYTES_LENGTH = -501 class-attribute instance-attribute #

BYTES_POP = -503 class-attribute instance-attribute #

BYTES_PUSH = -502 class-attribute instance-attribute #

ECRECOVER = -6 class-attribute instance-attribute #

FUNCTION_ADDRESS = -1003 class-attribute instance-attribute #

FUNCTION_GAS = -1002 class-attribute instance-attribute #

FUNCTION_SELECTOR = -1000 class-attribute instance-attribute #

FUNCTION_VALUE = -1001 class-attribute instance-attribute #

GASLEFT = -7 class-attribute instance-attribute #

KECCAK256 = -8 class-attribute instance-attribute #

LOG0 = -10 class-attribute instance-attribute #

LOG1 = -11 class-attribute instance-attribute #

LOG2 = -12 class-attribute instance-attribute #

LOG3 = -13 class-attribute instance-attribute #

LOG4 = -14 class-attribute instance-attribute #

MSG = -15 class-attribute instance-attribute #

MSG_DATA = -200 class-attribute instance-attribute #

MSG_SENDER = -201 class-attribute instance-attribute #

MSG_SIG = -202 class-attribute instance-attribute #

MSG_VALUE = -203 class-attribute instance-attribute #

MULMOD = -16 class-attribute instance-attribute #

NOW = -17 class-attribute instance-attribute #

REQUIRE = -18 class-attribute instance-attribute #

REVERT = -19 class-attribute instance-attribute #

RIPEMD160 = -20 class-attribute instance-attribute #

SELFDESTRUCT = -21 class-attribute instance-attribute #

SHA256 = -22 class-attribute instance-attribute #

SHA3 = -23 class-attribute instance-attribute #

STRING_CONCAT = -600 class-attribute instance-attribute #

SUICIDE = -24 class-attribute instance-attribute #

SUPER = -25 class-attribute instance-attribute #

THIS = -28 class-attribute instance-attribute #

TX = -26 class-attribute instance-attribute #

TX_GASPRICE = -300 class-attribute instance-attribute #

TX_ORIGIN = -301 class-attribute instance-attribute #

TYPE = -27 class-attribute instance-attribute #

TYPE_CREATION_CODE = -801 class-attribute instance-attribute #

TYPE_INTERFACE_ID = -803 class-attribute instance-attribute #

TYPE_MAX = -805 class-attribute instance-attribute #

TYPE_MIN = -804 class-attribute instance-attribute #

TYPE_NAME = -800 class-attribute instance-attribute #

TYPE_RUNTIME_CODE = -802 class-attribute instance-attribute #

USER_DEFINED_VALUE_TYPE_UNWRAP = -1101 class-attribute instance-attribute #

USER_DEFINED_VALUE_TYPE_WRAP = -1100 class-attribute instance-attribute #

InlineAssemblyEvmVersion class #

Bases: StrEnum

Source code in wake/ir/enums.py
class InlineAssemblyEvmVersion(StrEnum):
    HOMESTEAD = "homestead"
    TANGERINE_WHISTLE = "tangerineWhistle"
    SPURIOUS_DRAGON = "spuriousDragon"
    BYZANTIUM = "byzantium"
    CONSTANTINOPLE = "constantinople"
    PETERSBURG = "petersburg"
    ISTANBUL = "istanbul"
    BERLIN = "berlin"
    LONDON = "london"
    PARIS = "paris"
    SHANGHAI = "shanghai"
    CANCUN = "cancun"
    PRAGUE = "prague"

BERLIN = 'berlin' class-attribute instance-attribute #

BYZANTIUM = 'byzantium' class-attribute instance-attribute #

CANCUN = 'cancun' class-attribute instance-attribute #

CONSTANTINOPLE = 'constantinople' class-attribute instance-attribute #

HOMESTEAD = 'homestead' class-attribute instance-attribute #

ISTANBUL = 'istanbul' class-attribute instance-attribute #

LONDON = 'london' class-attribute instance-attribute #

PARIS = 'paris' class-attribute instance-attribute #

PETERSBURG = 'petersburg' class-attribute instance-attribute #

PRAGUE = 'prague' class-attribute instance-attribute #

SHANGHAI = 'shanghai' class-attribute instance-attribute #

SPURIOUS_DRAGON = 'spuriousDragon' class-attribute instance-attribute #

TANGERINE_WHISTLE = 'tangerineWhistle' class-attribute instance-attribute #

InlineAssemblyFlag class #

Bases: StrEnum

Source code in wake/ir/enums.py
class InlineAssemblyFlag(StrEnum):
    MEMORY_SAFE = "memory-safe"

MEMORY_SAFE = 'memory-safe' class-attribute instance-attribute #

InlineAssemblySuffix class #

Bases: StrEnum

Source code in wake/ir/enums.py
class InlineAssemblySuffix(StrEnum):
    SLOT = "slot"
    OFFSET = "offset"
    LENGTH = "length"
    ADDRESS = "address"
    SELECTOR = "selector"

ADDRESS = 'address' class-attribute instance-attribute #

LENGTH = 'length' class-attribute instance-attribute #

OFFSET = 'offset' class-attribute instance-attribute #

SELECTOR = 'selector' class-attribute instance-attribute #

SLOT = 'slot' class-attribute instance-attribute #

LiteralKind class #

Bases: StrEnum

Kind of a Literal expression node.

Source code in wake/ir/enums.py
class LiteralKind(StrEnum):
    """
    Kind of a [Literal][wake.ir.expressions.literal.Literal] expression node.
    """

    BOOL = "bool"
    NUMBER = "number"
    STRING = "string"
    HEX_STRING = "hexString"
    UNICODE_STRING = "unicodeString"

BOOL = 'bool' class-attribute instance-attribute #

HEX_STRING = 'hexString' class-attribute instance-attribute #

NUMBER = 'number' class-attribute instance-attribute #

STRING = 'string' class-attribute instance-attribute #

UNICODE_STRING = 'unicodeString' class-attribute instance-attribute #

MagicTypeKind class #

Bases: StrEnum

Kind of a Magic type.

Source code in wake/ir/enums.py
class MagicTypeKind(StrEnum):
    """
    Kind of a [Magic][wake.ir.types.Magic] type.
    """

    BLOCK = "block"
    MESSAGE = "message"
    TRANSACTION = "transaction"
    ABI = "abi"
    META_TYPE = "meta_type"

ABI = 'abi' class-attribute instance-attribute #

BLOCK = 'block' class-attribute instance-attribute #

MESSAGE = 'message' class-attribute instance-attribute #

META_TYPE = 'meta_type' class-attribute instance-attribute #

TRANSACTION = 'transaction' class-attribute instance-attribute #

ModifierInvocationKind class #

Bases: StrEnum

Kind of a ModifierInvocation meta node.

Source code in wake/ir/enums.py
class ModifierInvocationKind(StrEnum):
    """
    Kind of a [ModifierInvocation][wake.ir.meta.modifier_invocation.ModifierInvocation] meta node.
    """

    MODIFIER_INVOCATION = "modifierInvocation"
    BASE_CONSTRUCTOR_SPECIFIER = "baseConstructorSpecifier"

BASE_CONSTRUCTOR_SPECIFIER = 'baseConstructorSpecifier' class-attribute instance-attribute #

MODIFIER_INVOCATION = 'modifierInvocation' class-attribute instance-attribute #

Mutability class #

Bases: StrEnum

Mutability of a VariableDeclaration declaration node.

Source code in wake/ir/enums.py
class Mutability(StrEnum):
    """
    Mutability of a [VariableDeclaration][wake.ir.declarations.variable_declaration.VariableDeclaration] declaration node.
    """

    MUTABLE = "mutable"
    IMMUTABLE = "immutable"
    CONSTANT = "constant"

CONSTANT = 'constant' class-attribute instance-attribute #

IMMUTABLE = 'immutable' class-attribute instance-attribute #

MUTABLE = 'mutable' class-attribute instance-attribute #

StateMutability class #

Bases: StrEnum

State mutability of:

In the case of ElementaryTypeName, the state mutability is specified only for the address type and can be either NONPAYABLE or PAYABLE.

Source code in wake/ir/enums.py
class StateMutability(StrEnum):
    """
    State mutability of:

    - [Function][wake.ir.types.Function] type,
    - [FunctionDefinition][wake.ir.declarations.function_definition.FunctionDefinition] declaration,
    - [ElementaryTypeName][wake.ir.type_names.elementary_type_name.ElementaryTypeName] and [FunctionTypeName][wake.ir.type_names.function_type_name.FunctionTypeName] type names.

    In the case of [ElementaryTypeName][wake.ir.type_names.elementary_type_name.ElementaryTypeName], the state mutability is specified only for the `address` type and can be either [NONPAYABLE][wake.ir.enums.StateMutability.NONPAYABLE] or [PAYABLE][wake.ir.enums.StateMutability.PAYABLE].
    """

    PAYABLE = "payable"
    PURE = "pure"
    NONPAYABLE = "nonpayable"
    VIEW = "view"

NONPAYABLE = 'nonpayable' class-attribute instance-attribute #

PAYABLE = 'payable' class-attribute instance-attribute #

PURE = 'pure' class-attribute instance-attribute #

VIEW = 'view' class-attribute instance-attribute #

UnaryOpOperator class #

Bases: StrEnum

Unary operation operator used in an UnaryOperation expression.

Source code in wake/ir/enums.py
class UnaryOpOperator(StrEnum):
    """
    Unary operation operator used in an [UnaryOperation][wake.ir.expressions.unary_operation.UnaryOperation] expression.
    """

    PLUS_PLUS = r"++"
    MINUS_MINUS = r"--"
    MINUS = r"-"
    NOT = r"!"
    TILDE = r"~"
    DELETE = "delete"

DELETE = 'delete' class-attribute instance-attribute #

MINUS = '-' class-attribute instance-attribute #

MINUS_MINUS = '--' class-attribute instance-attribute #

NOT = '!' class-attribute instance-attribute #

PLUS_PLUS = '++' class-attribute instance-attribute #

TILDE = '~' class-attribute instance-attribute #

Visibility class #

Bases: StrEnum

Visibility of:

Source code in wake/ir/enums.py
class Visibility(StrEnum):
    """
    Visibility of:

    - [FunctionTypeName][wake.ir.type_names.function_type_name.FunctionTypeName] type name,
    - [FunctionDefinition][wake.ir.declarations.function_definition.FunctionDefinition], [ModifierDefinition][wake.ir.declarations.modifier_definition.ModifierDefinition], [StructDefinition][wake.ir.declarations.struct_definition.StructDefinition] and [VariableDeclaration][wake.ir.declarations.variable_declaration.VariableDeclaration] declarations.
    """

    EXTERNAL = "external"
    PUBLIC = "public"
    INTERNAL = "internal"
    PRIVATE = "private"

EXTERNAL = 'external' class-attribute instance-attribute #

INTERNAL = 'internal' class-attribute instance-attribute #

PRIVATE = 'private' class-attribute instance-attribute #

PUBLIC = 'public' class-attribute instance-attribute #

YulLiteralKind class #

Bases: StrEnum

Kind of a YulLiteral node.

Source code in wake/ir/enums.py
class YulLiteralKind(StrEnum):
    """
    Kind of a [YulLiteral][wake.ir.yul.literal.YulLiteral] node.
    """

    NUMBER = "number"
    STRING = "string"
    BOOL = "bool"

BOOL = 'bool' class-attribute instance-attribute #

NUMBER = 'number' class-attribute instance-attribute #

STRING = 'string' class-attribute instance-attribute #