-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
bugSomething isn't workingSomething isn't working
Description
If we write something like:
id (a: t) (b: t) -> t = b
This should be the same as writing:
id a b: t -> t -> t = b
That is, the type variable t across the annotations for a, b, and the return type should be quantified as the same name.
However, the lowering pass lowers these as three separate type annotations, which means they technically become separately quantified, since they reside in three separate type annotations.
I fear this kind of scoping might be tricky to get recover in the type-checking phase, so I should fix the lowering phase to collapse the three annotations into a single type annotation.
@XijiaoLi something to keep in mind while you work on type inference; to be safe, stick with the postfix type annotation syntax (using :) for now.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working