what's the difference between the lambda expression
λ {(tr u) → refl}
and without braces,
λ (tr u) → refl
I noticed that using one or the other causes an error.
While proving lemman 3.9.1 of the HoTT book:
∀ {n : Level} {P : Set n} → isMereProposition P → P ≃ || P ||
This proof was causing errors:
unique-choice {n} {P} PisProp = ⟨ tr , ⟨ ⟨ inverse-tr , (λ (tr u) → refl) ⟩ ,
⟨ inverse-tr , (λ u → refl) ⟩ ⟩ ⟩ where
inverse-tr : || P || → P
inverse-tr = λ (tr u) → u
while this one did not:
unique-choice {n} {P} PisProp = ⟨ tr , ⟨ ⟨ inverse-tr , (λ {(tr u) → refl}) ⟩ ,
⟨ inverse-tr , (λ u → refl) ⟩ ⟩ ⟩ where
inverse-tr : || P || → P
inverse-tr = λ {(tr u) → u}