Fix labels expecting a name instead of '::' to close
This commit is contained in:
parent
6193441621
commit
c7ac2cf091
@ -830,7 +830,7 @@ class Parser
|
|||||||
{
|
{
|
||||||
throw new Exception($"Index {index} out of bounds of {tokens.Length}, expected `::` after label name starting at {startRegion}");
|
throw new Exception($"Index {index} out of bounds of {tokens.Length}, expected `::` after label name starting at {startRegion}");
|
||||||
}
|
}
|
||||||
if(tokens[index].type != TokenType.Name)
|
if(tokens[index].type != TokenType.ColonColon)
|
||||||
{
|
{
|
||||||
throw new Exception($"{tokens[index].region}: Expected `::` after label name starting at {startRegion}, got {tokens[index].type}");
|
throw new Exception($"{tokens[index].region}: Expected `::` after label name starting at {startRegion}, got {tokens[index].type}");
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user