feat: implement objects and classes

This commit is contained in:
samsonium
2026-10-16 18:11:28 +03:00
parent 683dd08181
commit bc5d887ec4
22 changed files with 848 additions and 116 deletions
+4
View File
@@ -6,6 +6,7 @@
#include <stddef.h>
#include <stdint.h>
#include <vm/fzl_vm_env.h>
#include <vm/fzl_vm_object.h>
// VM descriptor
typedef struct
@@ -29,6 +30,9 @@ typedef struct
// Environment stack
fzl_vm_env_t *estack[256];
size_t etop;
fzl_vm_object_t *objects[256];
size_t objects_count;
} fzl_vm_t;
// Allocate FZL VM
+14
View File
@@ -0,0 +1,14 @@
#ifndef FZL_VM_OBJECT_H
#define FZL_VM_OBJECT_H
#include <common/fzl_value.h>
#include <stddef.h>
// Object descriptor
typedef struct
{
fzl_value_t *values;
size_t values_count;
} fzl_vm_object_t;
#endif // FZL_VM_OBJECT_H