| 394 | } |
| 395 | |
| 396 | extern "C" int ConsoleRunCompiledCodeMain(int argc, char *argv[], const void *entry_point, |
| 397 | const void *bytecodefb, size_t static_size, |
| 398 | const lobster::block_t *vtables) { |
| 399 | #ifdef USE_EXCEPTION_HANDLING |
| 400 | try |
| 401 | #endif |
| 402 | { |
| 403 | NativeRegistry nfr; |
| 404 | RegisterCoreLanguageBuiltins(nfr); |
| 405 | lobster::VM vm(CompiledInit(argc, argv, entry_point, bytecodefb, static_size, vtables, |
| 406 | DefaultLoadFile, nfr)); |
| 407 | vm.EvalProgram(); |
| 408 | } |
| 409 | #ifdef USE_EXCEPTION_HANDLING |
| 410 | catch (string &s) { |
| 411 | LOG_ERROR(s); |
| 412 | return 1; |
| 413 | } |
| 414 | #endif |
| 415 | return 0; |
| 416 | } |
| 417 | |
| 418 | SubFunction::~SubFunction() { delete body; } |
| 419 |
nothing calls this directly
no test coverage detected