Skip to content

Errors ​

These mnemonics create and inspect Error objects. See CandleVM error opcodes for runtime behavior.

CASM mnemonicCandleVM opcodeOperandsBehavior
err_newNewErrordestination, messageTakes a register containing a String, wraps its text in a new Error, and stores the object reference.
err_typeErrorTypedestination, errorStores the error type name in a newly allocated string.
err_messageErrorMessagedestination, errorStores the error message in a newly allocated string.

message and error are register operands, not quoted string literals. err_new does not accept the message text directly; construct it with str_new first.

Built for the Candle ecosystem · Powered by VitePress.