![]() |
Fun 0.41.5
The programming language that makes you have fun!
|
Implements the OP_RUST_HELLO_ARGS opcode (conditional build). More...
Go to the source code of this file.
Functions | |
| free_value (vmsg) | |
| if (msg) | |
| push_value (vm, make_nil()) | |
Variables | |
| case | OP_RUST_HELLO_ARGS |
| char * | msg = value_to_string_alloc(&vmsg) |
| else | |
| break | |
Implements the OP_RUST_HELLO_ARGS opcode (conditional build).
Demonstrates passing a VM value to Rust. Converts the top stack value to a string, calls into Rust to print/log it, and pushes Nil. When Rust support is disabled, the argument is still popped and freed to keep the stack sane, then Nil is pushed after raising an error message. OP_RUST_HELLO_ARGS: (msg:any) -> Nil
Behavior (FUN_WITH_RUST=ON):
Behavior (FUN_WITH_RUST=OFF):
Definition in file hello_args.c.
| free_value | ( | vmsg | ) |
| if | ( | msg | ) |
Definition at line 37 of file hello_args.c.
| push_value | ( | vm | , |
| make_nil() | ) |
| break |
Definition at line 51 of file hello_args.c.
| else |
Definition at line 40 of file hello_args.c.
| char* msg = value_to_string_alloc(&vmsg) |
Definition at line 35 of file hello_args.c.
| case OP_RUST_HELLO_ARGS |
Definition at line 32 of file hello_args.c.