improve performance for integers

This commit is contained in:
William Bell
2025-08-30 03:29:02 +01:00
parent 4fc28d3b76
commit 4f91bf48f3
16 changed files with 456 additions and 187 deletions

View File

@@ -40,6 +40,7 @@ typedef struct {
typedef struct {
uint8_t registerCount;
uint8_t registerAssignment;
DArray *return_jumps;
DArray bytecode;
ConstantArena constants;
@@ -74,7 +75,13 @@ struct ArgonObject {
struct hashmap_GC *dict;
bool as_bool;
union {
mpq_t *as_number;
struct as_number {
bool is_int64;
union {
mpq_t *mpq;
int64_t i64;
} n;
}as_number;
struct string_struct as_str;
native_fn native_fn;
struct argon_function_struct argon_fn;