← Back to context

Comment by almost

6 hours ago

It's probably worth being up front about what your do syntax actually does. A generator is not as general as "do", Python doesn't have call/cc or anything like that. I checked and you (or Claude I guess) do it by rerunning the whole thing each time for things like the list monad which is not something I think anyone would want for anything more than a toy.

I think the idea here is what is the best syntax for writing these type of programs in pythonic zen mode and then simply have the library truly optimize it for the run time. Which basically has to be a distributed compute substrate like pyspark or ray.

The goal is more correctness and fluent declarative readability to get business stuff done better, faster and cheaper