Pure vs. impure iterators in Go
https://jub0bs.com/posts/2025-05-29-pure-vs-impure-iterators-in-go/ [jub0bs.com]
2025-06-01 01:34
Because iterators are so powerful, they’re likely to mushroom in libraries even beyond Go’s standard library. Therefore, to forestall any confusion in the discourse about iterators, the terminology surrounding them should be as precise as possible.
This passage of the documentation seemingly divides iterators into two categories. I’ll attempt to elucidate them through a couple of examples.
source: HN