Mercurial > hg > Papers > 2020 > ryokka-master
view paper/src/AgdaStackSomeState.agda @ 11:831316a767e8
add hoare figure
author | ryokka |
---|---|
date | Mon, 10 Feb 2020 14:20:21 +0900 |
parents | c7acb9211784 |
children |
line wrap: on
line source
stackInSomeState : {l m : Level} {D : Set l} {t : Set m} (s : SingleLinkedStack D) -> Stack {l} {m} D {t} ( SingleLinkedStack D) stackInSomeState s = record { stack = s ; stackMethods = singleLinkedStackSpec } push->push->pop2 : {l : Level} {D : Set l} (x y : D) (s : SingleLinkedStack D) -> pushStack (stackInSomeState s) x (\s1 -> pushStack s1 y (\s2 -> pop2Stack s2 (\s3 y1 x1 -> (Just x ≡ x1) ∧ (Just y ≡ y1)))) push->push->pop2 {l} {D} x y s = record {pi1 = refl ; pi2 = refl}