No support for recursive HITs, but forward instead of squeeze and transp #62
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR attempts to fix the composition for directly recursive HITs like propositional truncation. It also implements the
forward
function instead oftransp
andsqueeze
that Simon and I came up with last week. Most things seem to work, in particular the first example provided in #35 now typechecks.However there is something very strange going on, we ported the setquot code to use the HIT version of propositional truncation instead of the impredicative encoding. The whole file typechecks, but when we try to compute some simple examples it never terminates (I killed the process after ~24h, with the impredicative encoding it terminates in 0.5s...). So there is either a bug in the implementation or the HITs are just very inefficient. I still vote for merging this code in order to make it easier to debug and try simpler examples.
Note that the bug in #47 is not fixed yet. That issue has to do with HITs where the path constructor involves a function (like in pushouts and coequalizers). If one runs the example in that file one sees that the f is not on the right side of the comp, so we have to use pres (from the paper) to correct it. Doing this in general for functions with more than 1 argument (where the arguments form a telescope) has to be worked out, but hopefully one can just directly generalize the pres operation from the paper.