Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add type lambdas #937

Open
johnynek opened this issue Feb 21, 2023 · 0 comments
Open

add type lambdas #937

johnynek opened this issue Feb 21, 2023 · 0 comments

Comments

@johnynek
Copy link
Owner

we unify type application and curry types left to right, but sometimes we want to name types in a different order.

If we had a direct notion of type lambda, we could change the order for both of those cases.

enum Tree[a, f]: Empty, Branch(item: a, children: f[Tree[a, f]])

# binary tree (has kind +* -> *)
[a] -> Tree[a, [x] -> (x, x)]
# linked list (has kind +* -> *)
[x] -> Tree[x, Option]

first do #936

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant