Skip to content

Commit 18f7fa8

Browse files
committed
Check the tag of the range end value
1 parent e5e9bd2 commit 18f7fa8

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

source/compiler/sc3.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1749,6 +1749,7 @@ static int hier2(value *lval)
17491749
error(8); /* must be constant expression */
17501750
if (end<=val)
17511751
error(50); /* invalid range */
1752+
check_tagmismatch(swtag,csetag,TRUE,-1);
17521753
while (++val<=end) {
17531754
casecount++;
17541755
csp=newval;

0 commit comments

Comments
 (0)