nlfiedler / bakeneko

Scheme R7RS interpreter in Go
BSD 3-Clause "New" or "Revised" License
2 stars 0 forks source link

Remove PairIterator interface for performance #35

Closed nlfiedler closed 10 years ago

nlfiedler commented 10 years ago

Based on Ewen's analysis of various Go iterator patterns, using an interface with an interator struct implementation is much slower than an iterator struct implementation without the corresponding iterator interface. That is, just remove PairIterator the interface and promote pairIterator the struct to "PairIterator".