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

Use instances for type classes #3

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Use instances for type classes #3

wants to merge 3 commits into from

Conversation

lemastero
Copy link
Owner

No description provided.


record Applicative (F : Type 𝑢 -> Type 𝑢) : Type (usuc 𝑢) where
record Applicative (F : Type 𝑢 -> Type 𝑢) {{ _ : Functor F }} : Type (usuc 𝑢) where
field

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So you're enforcing that F is a functor by demanding we have an (implicit) proof of that fact lying around somewhere? Nice.

; return-flatmap = {! !}
; flatmap-return = {! !}
; flatmap-compose = {! !}
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And here will be some proofs (instances). Cool. So we have a bit of work left to do. 👍🏼

@@ -1,15 +1,14 @@
{-# OPTIONS --without-K --exact-split --safe --no-unicode #-}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Interesting that you use --no-unicode. Just curious, why do you not like unicode?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Otherwise, those pragmas are exactly the ones I use in my agda-algebras library. 👍🏼

By the way, I think they're maybe phasing out --without-K in favor of --cubical-compatible. (I much prefer the old name as it seems to give a more precise description of what going on.)

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Drop pragma but awoid.

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

Successfully merging this pull request may close these issues.

2 participants