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

Restrict type of equivProof; Remove primIdJ; Rename ouc→outS everywhere #6032

Merged
merged 3 commits into from
Aug 17, 2022

Conversation

plt-amy
Copy link
Member

@plt-amy plt-amy commented Aug 16, 2022

Supersedes #6012, which I screwed up in my fork. Closes #5661, by ensuring that the fibre returned from equivTransp must be an extension of the given partial fibre: this implies that EQUIVFUN must have contractible fibres.

Closes #3714, by.. well, renaming inc and ouc everywhere.

Removes primIdJ, which can be recovered as either

idJ′ :  {ℓ ℓ'} {A : Set ℓ} {x : A} (P :  y  Id x y  Set ℓ') 
     P x (conid i1 (λ i  x))   {y} (p : Id x y)  P y p
idJ′ {x = x} P prefl =
  primIdElim P
    (λ φ y w 
      comp (λ i  P (outS w i) (conid (φ ∨ ~ i) λ j  outS w (i ∧ j)))
        (λ { i (φ = i1)  prefl }) prefl)

Or as

  IdJ :  {ℓ ℓ'} {A : Set ℓ} {x : A} (P :  y  Id x y  Set ℓ') 
      P x (conid i1 (λ i  x))   {y} (p : Id x y)  P y p
  IdJ {x = x} P prefl reflId = prefl

Updates the docs to mention pattern matching on reflId and to mention that cubical builtins are touchy even when they aren't deep magic.

@plt-amy plt-amy added type: enhancement Issues and pull requests about possible improvements cubical Cubical Agda paraphernalia: Paths, Glue, partial elements, hcomp, transp labels Aug 16, 2022
@plt-amy plt-amy added this to the 2.6.3 milestone Aug 16, 2022
@plt-amy plt-amy self-assigned this Aug 16, 2022
plt-amy and others added 2 commits August 16, 2022 16:03
Co-authored-by: Jon Sterling <jonsterling@users.noreply.github.com>
@plt-amy
Copy link
Member Author

plt-amy commented Aug 16, 2022

Someone should stop me from using DVCS.. "I'm not owned, I'm not owned, I continue to insist as I slowly shrink and turn into an octopus merge."

@andreasabel
Copy link
Member

Looks like you need to update a testcase:

+Issue5955.agda:6,39-81
+The module Agda.Builtin.Cubical.Sub doesn't export the following:
+  inc (did you mean 'inS'?)
+when scope checking the declaration
+  open import Agda.Builtin.Cubical.Sub renaming (primSubOut to outS;
+                                                 inc to inS)

https://github.com/agda/agda/runs/7866031500?check_suite_focus=true#step:9:30

... didn't I write that test case? Hoist by my own petard
@plt-amy
Copy link
Member Author

plt-amy commented Aug 17, 2022

I'm gonna go ahead and merge this since it's unlikely anyone will weep for primIdJ — the cubical library hides it when importing, and defines their own in terms of primIdElim (like in the OP).

@plt-amy plt-amy merged commit 0df094c into master Aug 17, 2022
@andreasabel
Copy link
Member

@plt-amy: Thanks for this fix! Would you mind adding this to the CHANGELOG?

plt-amy added a commit that referenced this pull request Aug 17, 2022
@andreasabel
Copy link
Member

Excellent, thanks!

@plt-amy plt-amy deleted the aliao/equiv-proof-ext-type branch October 27, 2022 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cubical Cubical Agda paraphernalia: Paths, Glue, partial elements, hcomp, transp type: enhancement Issues and pull requests about possible improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cubical does not ensure EQUIVFUN has left inverse Rename inc/ouc everywhere
2 participants