|
|
|
|
|
by foxes
15 days ago
|
|
An llm doesnt 'prefer' to use anything. Whats different to the effects system just being a type system? Isnt a function that opens a particular file still just a type? Perhaps dependent? Reminds me of mercury which has determinism of the function like type signatures. |
|
The effect system here is part of a type system (technically a type-and-effect system). Where a value type typically describes what value a computation returns, an effect describes which operations it can perform during evaluation.
The difference is that effects propagate through the call graph, so lower-level code cannot access disallowed resources without that authority appearing higher up. At runtime, world effects also require an explicit grant. In a typical value type system, lower-level code can introduce side effects without them appearing in the caller’s type.