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

Generic contexts #2

Open
omelkonian opened this issue Aug 31, 2019 · 0 comments
Open

Generic contexts #2

omelkonian opened this issue Aug 31, 2019 · 0 comments
Labels
enhancement New feature or request

Comments

@omelkonian
Copy link
Owner

Currently, we require the user to provide an associated type of contexts for the given type of expressions.

Conor McBride has shown that these correspond to just the type derivatives of the original type (http://strictlypositive.org/diff.pdf), so a good idea would be to generically derive these automatically. Alas, computing generic type derivatives can be very hard and impractical in the general case (mutually recursive types, etc...).

A more lightweight approach would be to use a Generic Zipper,
hence needing only one context type for all user-defined types, i.e.

data Context = Up | Down | Right

where up/down navigates the parent/children of a recursive datatype and right moves to the next sibling.

@omelkonian omelkonian added the enhancement New feature or request label Aug 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant