robert engels <reng...@ix.netcom.com>:
> Wouldn’t you normally pass a consumer or collector function into the 
> interator code? Then you only write the iterator once, and it is hidden.

I'll look into that approach.  There might be a readability issue there.

> Similar to how the sync.Map.Range() works.
> 
> Barring that, I don’t see how
> 
> for(i:=c.Iterator();i.HasNext();) {
>       v := i.Next()
> }
> 
> is that much more difficult to use - especially since you state it is a 
> custom iteration anyway?

I don't like the eyeball friction.

I write for long timescales.  Someone other than me will have to be able to
maintain this code someday.
-- 
                <a href="http://www.catb.org/~esr/";>Eric S. Raymond</a>

My work is funded by the Internet Civil Engineering Institute: https://icei.org
Please visit their site and donate: the civilization you save might be your own.


-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to