2022-02-10 07:14:29 +08:00
|
|
|
module Luau.Addr where
|
|
|
|
|
|
|
|
open import Agda.Builtin.Bool using (true; false)
|
|
|
|
open import Agda.Builtin.Equality using (_≡_)
|
|
|
|
open import Agda.Builtin.Nat using (Nat; _==_)
|
|
|
|
open import Agda.Builtin.String using (String)
|
|
|
|
open import Agda.Builtin.TrustMe using (primTrustMe)
|
2022-03-03 06:02:51 +08:00
|
|
|
open import Properties.Dec using (Dec; yes; no)
|
|
|
|
open import Properties.Equality using (_≢_)
|
2022-02-10 07:14:29 +08:00
|
|
|
|
|
|
|
Addr : Set
|
|
|
|
Addr = Nat
|
|
|
|
|
|
|
|
_≡ᴬ_ : (a b : Addr) → Dec (a ≡ b)
|
|
|
|
a ≡ᴬ b with a == b
|
2022-03-03 06:02:51 +08:00
|
|
|
a ≡ᴬ b | false = no p where postulate p : (a ≢ b)
|
2022-02-10 07:14:29 +08:00
|
|
|
a ≡ᴬ b | true = yes primTrustMe
|
|
|
|
|