5 ms·
While not mentioned in the blog post, the transducers implementation supports both early termination and result completion/flushing/cleanup.
by richhickey 12y ago
While not mentioned in the blog post, the transducers implementation supports both early termination and result completion/flushing/cleanup.
- dons 12y agothere does seem to be some overlap with stream fusion -- which was all about exploiting the optimization opportunities when separating the collection operation from the kernel performed on each element. We called the bits in the middle "step functions" , which could be combined with "consumers", "producers" and "transformers". And the algebra generalizes hugely (not just collections) but to things like concurrent processes, data flow programs etc. http://metagraph.org/papers/stream_fusion.pdf http://metagraph.org/papers/stream_fusion.pdf Things to think about in a non-Haskell settings: how do you prevent reordering side-effects? Can execeptions/non-termination being reordered be observed?