2020-02-10 19:27:58 +01:00
|
|
|
type storage is unit
|
|
|
|
|
|
|
|
type return is list (operation) * storage
|
|
|
|
|
|
|
|
function cb (const a : address; const s : storage) : return is
|
2019-11-19 17:19:12 -06:00
|
|
|
block {
|
2020-02-10 19:27:58 +01:00
|
|
|
const c : contract (unit) = get_entrypoint ("%cb", a)
|
2019-11-19 17:19:12 -06:00
|
|
|
}
|
2020-02-10 19:27:58 +01:00
|
|
|
with (list [transaction (unit, 0mutez, c)], s)
|
2020-01-28 13:44:33 +01:00
|
|
|
|
|
|
|
|
2020-02-10 19:27:58 +01:00
|
|
|
function cbo (const a : address; const s : storage) : return is
|
2020-01-28 13:44:33 +01:00
|
|
|
block {
|
2020-02-10 19:27:58 +01:00
|
|
|
const c : contract (unit) =
|
|
|
|
case (get_entrypoint_opt ("%cbo", a) : option (contract (unit))) of
|
|
|
|
Some (c) -> c
|
|
|
|
| None -> (failwith ("entrypoint not found") : contract (unit))
|
2020-01-28 13:44:33 +01:00
|
|
|
end
|
2020-02-10 19:27:58 +01:00
|
|
|
} with (list [transaction(unit, 0mutez, c)], s)
|