mirror of
https://github.com/cc65/cc65.git
synced 2024-12-27 15:29:46 +00:00
Add a missing type in range check
git-svn-id: svn://svn.cc65.org/cc65/trunk@1038 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
parent
ffd9db8b61
commit
f0ed4af252
@ -142,13 +142,15 @@ void SwitchStatement (void)
|
||||
Error ("Range error");
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
case T_SHORT:
|
||||
case T_INT:
|
||||
if (Val < -32768 || Val > 32767) {
|
||||
Error ("Range error");
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
case T_USHORT:
|
||||
case T_UINT:
|
||||
if (Val < 0 || Val > 65535) {
|
||||
Error ("Range error");
|
||||
@ -225,7 +227,7 @@ void SwitchStatement (void)
|
||||
|
||||
/* Eat the closing curly brace */
|
||||
NextToken ();
|
||||
|
||||
|
||||
/* Free the case value tree */
|
||||
FreeCaseNodeColl (Nodes);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user