{-# OPTIONS --cubical-compatible --safe #-}
module Function.Strict where
open import Agda.Builtin.Equality using (_≡_)
open import Function.Base using (flip)
open import Level using (Level)
private
variable
a b : Level
A B : Set a
infixl 0 _!|>_ _!|>′_
infixr -1 _$!_ _$!′_
open import Agda.Builtin.Strict public
renaming
( primForce to force
; primForceLemma to force-≡
)
_$!_ : ∀ {A : Set a} {B : A → Set b} →
((x : A) → B x) → ((x : A) → B x)
f $! x = force x f
_!|>_ : ∀ {A : Set a} {B : A → Set b} →
(a : A) → (∀ a → B a) → B a
_!|>_ = flip _$!_
seq : A → B → B
seq a b = force a (λ _ → b)
seq-≡ : (a : A) (b : B) → seq a b ≡ b
seq-≡ a b = force-≡ a (λ _ → b)
force′ : A → (A → B) → B
force′ = force
force′-≡ : (a : A) (f : A → B) → force′ a f ≡ f a
force′-≡ = force-≡
_$!′_ : (A → B) → (A → B)
_$!′_ = _$!_
_!|>′_ : A → (A → B) → B
_!|>′_ = _!|>_