-
Notifications
You must be signed in to change notification settings - Fork 40
Show instances for ground types #1123
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
base: master
Are you sure you want to change the base?
Conversation
|
The current implementation can already generate the following core code for type MaybeInt {
Nothing()
Just(x: Int, y: Int)
}but when being called in main like this the compiler fails in Transformer with |
|
Since it is a "user defined" function, you need to call it with App, not PureApp |
4de036e to
7f9a458
Compare
eca7730 to
c36c748
Compare
f3bd2d0 to
49b2f52
Compare
dd371a4 to
c75522c
Compare
- Start synthesizing all show definitions, not just missing ones
Then we don't need to filter out the definition
also delete old show functions, this works for all non-generic data types
also greatly shorten the functions needed for data types
show.effekt has a demo of everything that works for now
these can eventually be removed, when monomorphization is merged, but are required for now
7572311 to
ab5a850
Compare
Implement new Core -> Core Phase which
synthesizes
showdefinitions for any type based on ground show definitionsFor example
could generate something along the lines of