Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Print out "void" instead of "(null)" when printing out AST.
  • Loading branch information
icculus committed Sep 21, 2010
1 parent d268f63 commit 6009152
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion mojoshader_compiler.c
Expand Up @@ -2009,7 +2009,9 @@ static void print_ast(void *ast)
case FNSTORECLS_NONE: break;
case FNSTORECLS_INLINE: printf("inline "); break;
} // switch
printf("%s %s(", ((FunctionSignature *) ast)->datatype,
printf("%s %s(",
((FunctionSignature *) ast)->datatype ?
((FunctionSignature *) ast)->datatype : "void",
((FunctionSignature *) ast)->identifier);
print_ast(((FunctionSignature *) ast)->args);
printf(")");
Expand Down

0 comments on commit 6009152

Please sign in to comment.