Comment

Comment by the_duke

Very interesting analysis.

I'm fascinated with effect systems.

In theory they have the potential to make code both simpler and more powerful, because many complex abstractions like generators, async/await, error propagation, injected context, etc can all be built on a simple extensible language primitive.

The by far nicest implementation I've seen is Koka lang [1]. Unfortunately it's bound to be a small research language.

In practice I do wonder though if that much power won't make code very confusing to read and write, and if the general programmer should be trusted with that much flexibility.

For Rust specifically, I do wonder how generic effects could slot into a language that was not designed for them upfront, without compromising the design and DX.

[1] https://koka-lang.github.io/koka/doc/index.html

parent the_duke 2 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton