diff options
author | A404M <ahmadmahmoudiprogrammer@gmail.com> | 2025-04-26 02:10:25 +0330 |
---|---|---|
committer | A404M <ahmadmahmoudiprogrammer@gmail.com> | 2025-04-26 02:10:25 +0330 |
commit | b581b5918219a5f5169d59faca6f4dee20531482 (patch) | |
tree | ac25330ee8de7ac0d28813edbc4c2be892e2c9b4 /src/runner/runner.c | |
parent | 85bfc724dd2bdaa2259512c1b8ab21f7dfeca8f1 (diff) |
some small changes
Diffstat (limited to 'src/runner/runner.c')
-rw-r--r-- | src/runner/runner.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/runner/runner.c b/src/runner/runner.c index f33f056..3ab6bfc 100644 --- a/src/runner/runner.c +++ b/src/runner/runner.c @@ -186,11 +186,13 @@ AstTree *runAstTreeBuiltin(AstTree *tree, AstTreeScope *scope, *newValue = (i64)value; ret = newAstTree(AST_TREE_TOKEN_VALUE_INT, newValue, &AST_TREE_I64_TYPE, NULL, NULL); + #ifdef FLOAT_16_SUPPORT } else if (typeIsEqual(to, &AST_TREE_F16_TYPE)) { AstTreeFloat *newValue = a404m_malloc(sizeof(*newValue)); *newValue = (f16)value; ret = newAstTree(AST_TREE_TOKEN_VALUE_FLOAT, newValue, &AST_TREE_F16_TYPE, NULL, NULL); + #endif } else if (typeIsEqual(to, &AST_TREE_F32_TYPE)) { AstTreeFloat *newValue = a404m_malloc(sizeof(*newValue)); *newValue = (f32)value; @@ -258,11 +260,13 @@ AstTree *runAstTreeBuiltin(AstTree *tree, AstTreeScope *scope, *newValue = (i64)value; ret = newAstTree(AST_TREE_TOKEN_VALUE_INT, newValue, &AST_TREE_I64_TYPE, NULL, NULL); + #ifdef FLOAT_16_SUPPORT } else if (typeIsEqual(to, &AST_TREE_F16_TYPE)) { AstTreeFloat *newValue = a404m_malloc(sizeof(*newValue)); *newValue = (f16)value; ret = newAstTree(AST_TREE_TOKEN_VALUE_FLOAT, newValue, &AST_TREE_F16_TYPE, NULL, NULL); + #endif } else if (typeIsEqual(to, &AST_TREE_F32_TYPE)) { AstTreeFloat *newValue = a404m_malloc(sizeof(*newValue)); *newValue = (f32)value; @@ -330,11 +334,13 @@ AstTree *runAstTreeBuiltin(AstTree *tree, AstTreeScope *scope, *newValue = (i64)value; ret = newAstTree(AST_TREE_TOKEN_VALUE_INT, newValue, &AST_TREE_I64_TYPE, NULL, NULL); + #ifdef FLOAT_16_SUPPORT } else if (typeIsEqual(to, &AST_TREE_F16_TYPE)) { AstTreeFloat *newValue = a404m_malloc(sizeof(*newValue)); *newValue = (f16)value; ret = newAstTree(AST_TREE_TOKEN_VALUE_FLOAT, newValue, &AST_TREE_F16_TYPE, NULL, NULL); + #endif } else if (typeIsEqual(to, &AST_TREE_F32_TYPE)) { AstTreeFloat *newValue = a404m_malloc(sizeof(*newValue)); *newValue = (f32)value; |