mirror of
https://github.com/ProgramSnail/Lama.git
synced 2025-12-17 04:08:44 +00:00
bytecode compiler impirsts and external functions call support, byyterun imports and external functions calls parsing, initial impl of module manager
This commit is contained in:
parent
2cd7afe0c5
commit
0a26953318
11 changed files with 409 additions and 205 deletions
19
byterun/include/module_manager.h
Normal file
19
byterun/include/module_manager.h
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
#pragma once
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include "utils.h"
|
||||
|
||||
struct ModSearchResult {
|
||||
ssize_t symbol_offset; // < 0 => not found
|
||||
uint32_t mod_id;
|
||||
bytefile *mod_file;
|
||||
};
|
||||
|
||||
void mod_add_search_path(const char *path);
|
||||
|
||||
bytefile *mod_get(uint32_t id);
|
||||
|
||||
int32_t mod_load(const char *name); // < 0 => not found
|
||||
|
||||
struct ModSearchResult mod_search_pub_symbol(const char *name);
|
||||
Loading…
Add table
Add a link
Reference in a new issue