Core: Fix null pointer crash

This commit is contained in:
Krzosa Karol
2023-04-21 23:08:35 +02:00
parent bbd8b0ab91
commit 4657b4460e
2 changed files with 3 additions and 3 deletions

View File

@@ -3,8 +3,8 @@ call "..\misc\compile_setup.bat"
bld --dont_compile_core
cd build
rem core_main.exe rtsgame/main.core
core_main.exe examples/unions.core
core_main.exe rtsgame/main.core
rem core_main.exe examples/unions.core
bld --dont_compile_core --link=vendor/raylib/windows/raylibdll.lib
rem build\generated_main.exe
cd ..

View File

@@ -582,7 +582,7 @@ gen_ast(Ast *ast) {
CASE(RETURN, Return) {
gen("return ");
gen_expr(node->expr);
if (node->expr) gen_expr(node->expr);
gen(";");
BREAK();
}