clean up null object

This commit is contained in:
IlyaShurupov 2024-03-25 11:36:29 +03:00
parent 55daf0f303
commit acaa086943
6 changed files with 30 additions and 50 deletions

View file

@ -34,6 +34,11 @@ namespace tp::obj {
Interpreter* interp = nullptr;
save_load_callbacks* sl_callbacks[SAVE_LOAD_MAX_CALLBACK_SLOTS]{};
alni sl_callbacks_load_idx = 0;
struct NullObject* nullObject = nullptr;
struct BoolObject* boolTrueObject = nullptr;
struct BoolObject* boolFalseObject = nullptr;
};
struct objects_api {
@ -105,5 +110,8 @@ namespace tp::obj {
static bool isType(const char* name);
static const ObjectType* getType(const char* name);
static NullObject* getNull();
static NullObject* getNullReferenced();
};
}