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

Abbreviate repeated qualifiers in instance declarations #121

Open
wisnesky opened this issue Nov 20, 2018 · 1 comment
Open

Abbreviate repeated qualifiers in instance declarations #121

wisnesky opened this issue Nov 20, 2018 · 1 comment
Assignees

Comments

@wisnesky
Copy link
Contributor

I'd like to write 'TyMap f `[a,b,c]' instead of (f a, f b, f c) in instance declarations a la Marco's trick for regular function type declarations, but it doesn't quite work.

instance (Show var, Show ty, Show sym, Show en, Show fk, Show att, Show gen, Show sk,
          Show x, Show y, Show gen', Show sk', Show x', Show y')
  => Show (Transform var ty sym en fk att gen sk x y gen' sk' x' y') where

~~>

instance (Show `[var, ty sym, ...]) =>
@wisnesky
Copy link
Contributor Author

This one is especially important if we want to avoid unnecessary qualifiers while also keeping lists of qualifiers textually short.

marcosh added a commit that referenced this issue Nov 22, 2018
marcosh added a commit that referenced this issue Nov 24, 2018
marcosh added a commit that referenced this issue Nov 28, 2018
marcosh added a commit that referenced this issue Nov 28, 2018
epost pushed a commit that referenced this issue Dec 6, 2018
* Abbreviate repeated qualifiers. #121
* Introduce TyMap, MultiTyMap. #121
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

3 participants