← Back to team overview

ooc-dev team mailing list archive

Re: Back/front methods for Iterable (and reverse iterators)

 

El jue, 03-06-2010 a las 05:59 -0700, Noel Cower escribió:
> Responding to what Iván said, so apologies for having Amos's response
> in there too.
> 
Thanks for the explanation in the rest of your message about Iterators.
I think I'm now a bit more clear about their design.

> That said, the generic function really seems like overkill to me, and
> I'd prefer not to ever have to type so much just for an iterator.

I'd prefer that, too. But I think a language can be tweaked to simplfy
the way it uses it's own core libraries (a great example of that is C#
events, that are syntax sugar for a big bunch of code lines using
event's dispatcher objects). As ooc syntax is not fully stabilized yet
(pr so I thought), now is the time to do that kind of improvements, if
the need for them is found. Later, it will be not so easy to do this
kind of changes. That's why I proposed to have a for syntax that
transparently inserts the expansion to a generic call.  

> 
> Anyhow, in short, I think we've got enough base iterator types to last
> us, don't think anymore are needed right now, and really don't want to
> use generics for the sake of using generics (or templates, in this
> case).  I'd use C++ if I wanted that.  

I apologized to Amos for my proposal about something is already
stablished. Blame my ignorance (and the pile of messages pending to be
read on my localbox from ooc mailing list). Agein, I'm sorry.


> Hopefully that makes sense, since I started writing this a while ago
> and I'm not sure about the coherency of my e-mails after I've tweaked
> them for so long.
> 
It helped me a lot, thanks.






Follow ups

References