From: Eric Mahurin Date: 2005-09-30T04:52:15+09:00 Subject: Re: Class and Iterator Design Question --- gabriele renzi wrote: > James Edward Gray II ha scritto: > > On Sep 28, 2005, at 5:10 AM, Florian Frank wrote: > > > >> I think enumerator should become part of Standard Ruby, > because it's > >> so damn useful. > > > > > > I believe that's the plan. I think all the standard > iterators are > > going to start returning enumerator objects when called > without a block. > > > > James Edward Gray II > > would'nt it make more sense to have yield work coroutinish > when called > withouth a block, basically integrating the enumerator > functionality in it? That sounds unnecesarily complex. If it is what I think you are talking about, you'd return some kind of object with a continuation when you hit a yield without a block (like a generator?). An example would help explain what you are talking about. I think the current plan with Enumerators sounds better. __________________________________ Yahoo! Mail - PC Magazine Editors' Choice 2005 http://mail.yahoo.com