diff --git a/source/compiler/tests/warning_250_251.pwn b/source/compiler/tests/warning_250_251.pwn index 1083e3f..4eb83fb 100644 --- a/source/compiler/tests/warning_250_251.pwn +++ b/source/compiler/tests/warning_250_251.pwn @@ -85,8 +85,11 @@ main() while(fread(f,line,sizeof(line),false) < m) {} // shouldn't warn about "f" or "m" not being modified fclose(f); - // Case 12: Warnings 250 and 251 don't work for global variables (yet?) - while (glbvar < 10) {} - for (glbvar = 0; glbvar < 10; ) {} + // Case 12: Warnings 250 and 251 shouldn't trigger when at least one global + // variable is used inside the loop condition, as globals can be modified + // from a function called from the loop body and currently there's no easy + // way to track this. + while (n < glbvar) {} + for (new i = 0; i < glbvar; ) {} }