In-reply-to » Go 1.22.0 introduces a new experiment for range functions. Have you tried them out? What do you think it can make easier to accomplish?

@xuu@txt.sour.is Oh, I wasn’t aware of this! Thanks for bringing it to my attention.

I do like that they move away from one shared variable per loop to an own one per iteration. That makes sooo much more sense. I don’t hit that often, but it happened a few times in the past and getting this figured out is not the easiest thing in the world.

I have to read up on the yield functions. From your examples I fear iterators would have been more useful. Let’s see.

⤋ Read More