+1
-1
@@ -25,7 +25,7 @@ int main(void) {
|
||||
furvm::mod_h furlangModule = context->emplace_module("furlang");
|
||||
furvm::function_h printFunc = furlangModule->emplace_function("print", 1, "print");
|
||||
furlangModule->set_native_function("print",
|
||||
[](furvm::executor& executor) { std::cout << executor.load_thing(0)->get<furvm::int_t>() << '\n'; });
|
||||
[](furvm::executor& executor) { std::cout << executor.load_thing(0)->integer() << '\n'; });
|
||||
|
||||
furvm::mod_h mainModule = context->emplace_module("main", s_bytecode.begin(), s_bytecode.end());
|
||||
furvm::function_h mainFunc = mainModule->emplace_function("main", 0, 0);
|
||||
|
||||
Reference in New Issue
Block a user