annotate src/CodeSegments.agda.replaced @ 1:73127e0ab57c

(none)
author soto@cr.ie.u-ryukyu.ac.jp
date Tue, 08 Sep 2020 18:38:08 +0900
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
1 cs2 : CodeSegment ds1 ds1
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
2 cs2 = cs id
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
3
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
4 cs1 : CodeSegment ds1 ds1
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
5 cs1 = cs (\d @$\rightarrow$@ goto cs2 d)
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
6
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
7 cs0 : CodeSegment ds0 ds1
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
8 cs0 = cs (\d @$\rightarrow$@ goto cs1 (record {c = (ds0.a d) + (ds0.b d)}))
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
9
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
10 main : ds1
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
11 main = goto cs0 (record {a = 100 ; b = 50})
soto@cr.ie.u-ryukyu.ac.jp
parents:
diff changeset
12