Skip to content

Commit

Permalink
Merge pull request #157 from VVWVV/fix_emit_crash
Browse files Browse the repository at this point in the history
Fixes crash with #emit and unused functions
  • Loading branch information
Zeex authored Jul 29, 2017
2 parents 6c2e5d0 + 223838d commit 55f0ac5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion source/compiler/sc2.c
Original file line number Diff line number Diff line change
Expand Up @@ -1330,7 +1330,8 @@ static int command(void)
/* mark function as "used" */
/* do NOT mark it as written as that has a different meaning for
* functions (marks them as "should return a value") */
markusage(sym,uREAD);
if (sc_status!=statSKIP)
markusage(sym,uREAD);
} else {
outval(sym->addr,FALSE);
/* mark symbol as "used", unknown whether for read or write */
Expand Down

0 comments on commit 55f0ac5

Please sign in to comment.