3 ms·
> So that's what I was doing there: codata and corecursion. Who woulda figured? I can't quite make out the tone of it, and guessing tone is a fool's game, so I
by JadeNB 6y ago
> So that's what I was doing there: codata and corecursion. Who woulda figured?
I can't quite make out the tone of it, and guessing tone is a fool's game, so I'll take it literally. I think that this is one thing that people miss who complain about the proliferation of mathematical terminology in modern functional programming. I see no reason to think that you're such a person, so, just to be clear, when I say 'you' below, I am addressing only a hypothetical such person, not actually you.
No-one wants to force you to think in terms of codata, coinduction, and corecursion if you're comfortable with your mental model of what lazy lists are doing; the point is rather to allow you to think in those terms—to leverage the vast theoretical power that already exists in the mathematics, rather than requiring it to be re-discovered in an ad hoc way.