PR modula2/117371: Add check for zero step in for loop
This patch is a follow on from PR modula2/117371 which could include
a check to enforce the ISO restriction on a zero for loop step.
gcc/m2/ChangeLog:
PR modula2/117371
* gm2-compiler/M2GenGCC.mod (PerformLastForIterator):
Add check for zero step value and issue an error message.
gcc/testsuite/ChangeLog:
PR modula2/117371
* gm2/iso/fail/forloopbyzero.mod: New test.
Signed-off-by:
Gaius Mulley <gaiusmod2@gmail.com>
Loading
Please register or sign in to comment