-
Notifications
You must be signed in to change notification settings - Fork 33
Expand file tree
/
Copy pathbug_annot1_lov.liq
More file actions
75 lines (53 loc) · 1.46 KB
/
bug_annot1_lov.liq
File metadata and controls
75 lines (53 loc) · 1.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
module C1 = struct
module C2 = struct
contract C3 = struct
type storage = unit
let%entry default (_x:int) _ = ([] : operation list), ()
end
contract C = struct
type t = { x : tez; y : bool }
type storage = unit
let%entry default (_x:t) _ = ([] : operation list), ()
(* val%entry default : t *)
let mc = 1tz
end
let my = 2tz
end
end
contract type C = sig
type t = { x : tez; y : bool }
(* type t = { x : timestamp; y : address } *)
type storage = unit
val%entry default : t
end
contract C = struct
type t = { x : tez; y : bool }
(* type t = { x : timestamp; y : address } *)
type storage = unit
let%entry default (_:t) s = [],s
end
module Y = C1.C2
module R = Y
contract F = C1.C2.C
contract X = R.C
type storage = address * address
let%entry default (_k : key_hash) storage =
(* let x = { C.x = 1tz + F.mc + Y.my ; C.y = true } in *)
(* let op = storage.(0).default
* { C.x = 1tz + F.mc + Y.my ; C.y = true }
* ~amount:0tz in *)
(* match [%handle C.default] storage.(0) with
* | None -> failwith ()
* | Some c ->
* let op = c.default
* (\* x *\)
* { C.x = 1tz + F.mc + Y.my ; C.y = true }
* ~amount:0tz in *)
match C.at storage.(0) with
| None -> failwith ()
| Some c ->
let op = c.default
(* x *)
{ C.x = 1tz + F.mc + Y.my ; C.y = true }
~amount:0tz in
[op], storage