[fpc-devel] for-in-index loop

Florian Klämpfl florian at freepascal.org
Thu Jan 24 21:56:27 CET 2013


Am 24.01.2013 21:35, schrieb Alexander Klenin:
> On Fri, Jan 25, 2013 at 7:30 AM, Florian Klämpfl <florian at freepascal.org> wrote:
>> Am 24.01.2013 20:36, schrieb Alexander Klenin:
>>> That's debatable.
>>
>> As long as there is only some few line idea, there cannot debated much.
> 
> It is more: an idea with implementation and tests ;)
> 
>> Just an example: what happens with i if I start to delete from s during
>> the for loop?
> 
> Exactly the same thing as in the current for-in loop: either a range check error
> of nothing, depending on what you delete.

How do you ensure this if I delete a char already processed? Will i be
adjusted? Or will the loop continue to run with an invalid i?



More information about the fpc-devel mailing list