module U = NUri
module C = Cps
-module S = Share
+module W = Share
module L = Log
module E = Entity
module H = Hierarchy
+module S = Status
module Z = Bag
module ZO = BagOutput
module ZE = BagEnvironment
ZE.get_entity f uri
| Z.Bind (l, id, Z.Abbr v, t) ->
let f xv xt tt =
- f (S.sh2 v xv t xt x (Z.bind_abbr l id)) (Z.bind_abbr l id xv tt)
+ f (W.sh2 v xv t xt x (Z.bind_abbr l id)) (Z.bind_abbr l id xv tt)
in
let f xv cc = b_type_of (f xv) st cc t in
let f xv = Z.push "type abbr" (f xv) c l id (Z.Abbr xv) in
type_of f st c v
| Z.Bind (l, id, Z.Abst u, t) ->
let f xu xt tt =
- f (S.sh2 u xu t xt x (Z.bind_abst l id)) (Z.bind_abst l id xu tt)
+ f (W.sh2 u xu t xt x (Z.bind_abst l id)) (Z.bind_abst l id xu tt)
in
let f xu cc = b_type_of (f xu) st cc t in
let f xu _ = Z.push "type abst" (f xu) c l id (Z.Abst xu) in
type_of f st c u
| Z.Bind (l, id, Z.Void, t) ->
let f xt tt =
- f (S.sh1 t xt x (Z.bind l id Z.Void)) (Z.bind l id Z.Void tt)
+ f (W.sh1 t xt x (Z.bind l id Z.Void)) (Z.bind l id Z.Void tt)
in
let f cc = b_type_of f st cc t in
Z.push "type void" f c l id Z.Void
L.unbox (succ level);
let f a =
(* L.warn (Printf.sprintf "Convertible: %b" a); *)
- if a then f (S.sh2 v xv t xt x Z.appl) (Z.appl xv tt)
+ if a then f (W.sh2 v xv t xt x Z.appl) (Z.appl xv tt)
else error3 c xv vv w
in
- ZR.are_convertible f ~si:st.E.si c w vv
+ ZR.are_convertible f ~si:st.S.si c w vv
| _ ->
error1 "not a function" c xt
in
| Z.Cast (u, t) ->
let f xu xt tt a =
(* L.warn (Printf.sprintf "Convertible: %b" a); *)
- if a then f (S.sh2 u xu t xt x Z.cast) xu else error3 c xt tt xu
+ if a then f (W.sh2 u xu t xt x Z.cast) xu else error3 c xt tt xu
in
- let f xu xt tt = ZR.are_convertible (f xu xt tt) ~si:st.E.si c xu tt in
+ let f xu xt tt = ZR.are_convertible (f xu xt tt) ~si:st.S.si c xu tt in
let f xu _ = b_type_of (f xu) st c t in
type_of f st c u