author | Christian Urban <urbanc@in.tum.de> |
Tue, 13 Apr 2010 07:40:54 +0200 | |
changeset 1818 | 37480540c1af |
parent 1773 | c0eac04ae3b4 |
child 2057 | 232595afb82e |
permissions | -rw-r--r-- |
1744
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
1 |
theory ExLetMult |
1773
c0eac04ae3b4
added README and moved examples into separate directory
Christian Urban <urbanc@in.tum.de>
parents:
1745
diff
changeset
|
2 |
imports "../Parser" |
1744
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
3 |
begin |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
4 |
|
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
5 |
atom_decl name |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
6 |
|
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
7 |
ML {* val _ = recursive := true *} |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
8 |
ML {* val _ = alpha_type := AlphaLst *} |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
9 |
ML {* val _ = cheat_equivp := true *} |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
10 |
nominal_datatype trm = |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
11 |
Vr "name" |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
12 |
| Ap "trm" "trm" |
1745
26c4653d76d1
Forgot to save before commit.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
1744
diff
changeset
|
13 |
| Lm x::"name" t::"trm" bind x in t |
1744
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
14 |
| Lt l::"lts" t::"trm" s::"trm" bind "bn l" in t, bind "bn l" in s |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
15 |
and lts = |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
16 |
Lnil |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
17 |
| Lcons "name" "trm" "lts" |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
18 |
binder |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
19 |
bn |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
20 |
where |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
21 |
"bn Lnil = []" |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
22 |
| "bn (Lcons x t l) = (atom x) # (bn l)" |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
23 |
|
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
24 |
thm trm_lts.eq_iff |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
25 |
thm trm_lts.induct |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
26 |
thm trm_lts.fv[simplified trm_lts.supp] |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
27 |
|
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
28 |
end |
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
29 |
|
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
30 |
|
00680cea0dde
Let with multiple bindings.
Cezary Kaliszyk <kaliszyk@in.tum.de>
parents:
diff
changeset
|
31 |