mirror of
https://github.com/krgamestudios/Toy.git
synced 2026-04-15 14:54:07 +10:00
Functions are successfully called, read more
Return keyword is not yet implemented. Functions are untested. See #163
This commit is contained in:
@@ -51,6 +51,7 @@ int test_sizeof_ast(void) {
|
||||
TEST_SIZEOF(Toy_AstVarAssign, 16 , 24);
|
||||
TEST_SIZEOF(Toy_AstVarAccess, 8 , 16);
|
||||
TEST_SIZEOF(Toy_AstFnDeclare, 16 , 32);
|
||||
TEST_SIZEOF(Toy_AstFnInvoke, 12 , 24);
|
||||
TEST_SIZEOF(Toy_AstPass, 4 , 4);
|
||||
TEST_SIZEOF(Toy_AstError, 4 , 4);
|
||||
TEST_SIZEOF(Toy_AstEnd, 4 , 4);
|
||||
|
||||
@@ -369,7 +369,7 @@ int test_value_stringify(void) {
|
||||
|
||||
//check
|
||||
if (string->info.type != TOY_STRING_LEAF ||
|
||||
strcmp(string->leaf.data, "null") != 0)
|
||||
strcmp(string->leaf.data, "<null>") != 0)
|
||||
{
|
||||
fprintf(stderr, TOY_CC_ERROR "ERROR: stringify 'null' failed\n" TOY_CC_RESET);
|
||||
Toy_freeString(string);
|
||||
@@ -395,7 +395,7 @@ int test_value_stringify(void) {
|
||||
|
||||
//check
|
||||
if (string->info.type != TOY_STRING_LEAF ||
|
||||
strcmp(string->leaf.data, "true") != 0)
|
||||
strcmp(string->leaf.data, "<true>") != 0)
|
||||
{
|
||||
fprintf(stderr, TOY_CC_ERROR "ERROR: stringify boolean 'true' failed\n" TOY_CC_RESET);
|
||||
Toy_freeString(string);
|
||||
@@ -421,7 +421,7 @@ int test_value_stringify(void) {
|
||||
|
||||
//check
|
||||
if (string->info.type != TOY_STRING_LEAF ||
|
||||
strcmp(string->leaf.data, "false") != 0)
|
||||
strcmp(string->leaf.data, "<false>") != 0)
|
||||
{
|
||||
fprintf(stderr, TOY_CC_ERROR "ERROR: stringify boolean 'false' failed\n" TOY_CC_RESET);
|
||||
Toy_freeString(string);
|
||||
|
||||
Reference in New Issue
Block a user