[fpc-devel] New feature discussion: for-in loop

Graeme Geldenhuys graemeg.lists at gmail.com
Tue Oct 20 10:03:48 CEST 2009


2009/10/20 Alexander Klenin <klenin at gmail.com>:
>> As an alternative to the very limited "for-in", I have a better and
>> more flexible design, using the Iterator design pattern.
>
> for-in is just a syntax sugar plus standard interface for the cost common usage
> of iterators. So they are not mutually exclusive at all.

Well, with for-in you can only loop through a list is a specific order
and direction. You can't peak forward, you can't move back, you can't
filter returned content.

So you, for-in is VERY LIMITED in my eyes, and a total waist of time.


-- 
Regards,
  - Graeme -


_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/



More information about the fpc-devel mailing list