unison/unison-src/transcripts/type-deps.md
2024-06-25 11:11:07 -07:00

586 B

Ensure type dependencies are properly considered in slurping

https://github.com/unisonweb/unison/pull/2821

scratch/main> builtins.merge

Define a type.

structural type Y = Y
scratch/main> add

Now, we update Y, and add a new type Z which depends on it.

structural type Z = Z Y
structural type Y = Y Nat

Adding should fail for BOTH definitions, Y needs an update and Z is blocked by Y.

scratch/main> add 
-- This shouldn't exist, because it should've been blocked.
scratch/main> view Z