mirror of
https://github.com/Sei-Lisa/LSL-PyOptimizer
synced 2025-07-01 15:48:21 +00:00
Still somewhat messy, but still reported as soon as it can be detected. If an ELSE token is detected at the top level, for example, the error position will be rewound to the state change and reported there. This means that in this situation: x() { if (1) { state default; x(2); } else ; } default{timer(){}} an error will be reported in x(2), because the ELSE hasn't been found at that point, therefore the state change statement isn't found to be at fault yet. However, in this case: x() { if (1) state default; else x(2); } default{timer(){}} the error WILL be reported at the state change statement. This commit also changes the position where the exception is reported, to be at the STATE token. As an inconsequential side effect, EParseCantChangeState takes precedence over undefined identifiers, in case the state change is to an undefined state, but only in cases where it can be immediately detected. |
||
---|---|---|
.. | ||
__init__.py | ||
lslbasefuncs.py | ||
lslcommon.py | ||
lsldeadcode.py | ||
lslextrafuncs.py | ||
lslfoldconst.py | ||
lslfuncopt.py | ||
lslfuncs.py | ||
lsljson.py | ||
lsllastpass.py | ||
lslloadlib.py | ||
lsloptimizer.py | ||
lsloutput.py | ||
lslparse.py | ||
lslrenamer.py |