open import Agda.Primitive
import Relation.Binary.PropositionalEquality as Eq
open Eq public
open Eq.≡-Reasoning
Suppose I have a dependent pair whose second element is irrelevant:
record ∃' {a b} (A : Set a) (B : A → Set b) : Set (a ⊔ b) where
constructor _,,_
field
fst : A
.snd : B fst
open ∃' public
syntax ∃' A (λ x → B) = ∃'[ x ∈ A ] B
infix 2 ∃'
infixr 4 _,,_
Let's say I happen to use it on a subsingleton, such as _≡_
:
module _ (X Y : Set) (f g : X → Y) where
K : Set
K = ∃'[ x ∈ X ] f x ≡ g x
How can I make use of this equality in a relevant context? For example, how can I prove this?
thm : ∀ (k : K) → f (fst k) ≡ g (fst k)
thm (x ,, eq) = {! !}