Issue4169.agda 741 B

12345678910111213141516171819202122232425262728293031323334
  1. -- Andreas, 2019-11-07, issue #4169 report and testcase by nad.
  2. -- Extra coercions needed when erased versions of functions are used.
  3. open import Agda.Builtin.Unit
  4. open import Common.IO
  5. data D : Set where
  6. c : D
  7. F : D → Set → Set
  8. F c A = A → A
  9. f : (d : D) (A : Set) → F d A → A → A -- 14
  10. f c A g = g
  11. f′ : (d : D) (A : Set) (P : Set → Set) -- 30
  12. (g : (A : Set) → F d (P A))
  13. → P A → P A
  14. f′ d A P g = f d (P A) (g A)
  15. module _ (id : (A : Set) → (A → A) → A → A) (G : Set → Set) where
  16. postulate
  17. g : (A : Set) → G A → G A
  18. g′ : (A : Set) → G A → G A
  19. g′ A s = g A s
  20. g″ : (A : Set) → G A → G A
  21. g″ A = id (G A) (f′ c A G g′)
  22. main : IO ⊤
  23. main = return _