module ahmed.day1 where open import Data.Product data Type : Set where Bool : Type _-→_ : Type → Type → Type data Term : Set where True : Term False : Term If_Then_Else_ : Term → Term → Term → Term λ[_::_]_ : Term → Type → Term → Term _∙_ : Term → Term → Term data isValue : Term → Set where TrueValue : isValue True FalseValue : isValue False LambdaValue : (x : Term) → (τ : Type) → (e : Term) → isValue (λ[ x :: τ ] e) Value = Σ Term isValue data evaluationContext : Set where dot : evaluationContext EIf_Then_Else_ : evaluationContext → Term → Term → evaluationContext EAppLeft : evaluationContext → Term → evaluationContext EAppRight : Value → evaluationContext → evaluationContext