Branch: Tag:

2003-05-30

2003-05-30 23:19:26 by Martin Stjernholm <mast@lysator.liu.se>

Fixed error checking for missing functions in iterator objects given to
foreach(). (foreach() would previously simply loop forever with index 0 and
value 0 if given something that isn't an iterator.)

Rev: src/iterators.cmod:1.42
Rev: src/testsuite.in:1.650

1: - test_true([["$Id: testsuite.in,v 1.649 2003/05/30 19:38:06 grubba Exp $"]]); + test_true([["$Id: testsuite.in,v 1.650 2003/05/30 23:19:26 mast Exp $"]]);      // This triggered a bug only if run sufficiently early.   test_compile_any([[#pike 7.2]])
6718:    return ret;   ]],315)    + test_eval_error([[ +  int i; +  foreach (class{}(); mixed a; mixed b) i++; +  return i; + ]]) +    // do-while   test_any(int e;string t=""; e=0; do{ t+=e; }while(++e<6); return t,"012345";)