tmaxloopiterations.nim 297 B

12345678910111213141516
  1. discard """
  2. errormsg: "interpretation requires too many iterations; if you are sure this is not a bug in your code"
  3. """
  4. # issue #9829
  5. macro foo(): untyped =
  6. let lines = ["123", "5423"]
  7. var idx = 0
  8. while idx < lines.len():
  9. if lines[idx].len() < 1:
  10. inc(idx)
  11. continue
  12. foo()