Past remaining tests #39

Merged
davidgmbb merged 18 commits from macro-tests into main 2025-06-19 16:16:21 +00:00
3 changed files with 791 additions and 82 deletions
Showing only changes of commit 51cad46ad6 - Show all commits

File diff suppressed because it is too large Load Diff

View File

@ -1029,7 +1029,6 @@ struct MacroDeclaration
{ {
Slice<Argument> arguments; Slice<Argument> arguments;
Slice<ConstantArgument> constant_arguments; Slice<ConstantArgument> constant_arguments;
TypeList types;
Type* return_type; Type* return_type;
Block* block; Block* block;
String name; String name;

View File

@ -2693,7 +2693,11 @@ fn Statement* parse_statement(Module* module, Scope* scope)
} break; } break;
case StatementStartKeyword::return_st: case StatementStartKeyword::return_st:
{ {
auto return_value = parse_value(module, scope, {}); Value* return_value = 0;
if (module->content[module->offset] != ';')
{
return_value = parse_value(module, scope, {});
}
statement->return_st = return_value; statement->return_st = return_value;
statement->id = StatementId::return_st; statement->id = StatementId::return_st;
} break; } break;