Errors
These mnemonics create and inspect Error objects. See CandleVM error opcodes for runtime behavior.
| CASM mnemonic | CandleVM opcode | Operands | Behavior |
|---|---|---|---|
err_new | NewError | destination, message | Takes a register containing a String, wraps its text in a new Error, and stores the object reference. |
err_type | ErrorType | destination, error | Stores the error type name in a newly allocated string. |
err_message | ErrorMessage | destination, error | Stores 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.