Modes.At_localityAbstract over whether a value is local or global.
module type Without_crossing = sig ... endAbstract over whether a value is local or global.
module type At_locality = sig ... endinclude At_localityPhantom type parameter for t representing that the inhabitant may be local. This type does not cross locality to enforce the relationship between mode-crossing and phantom types in the with clauses on type t below.
Phantom type parameter for t which represents that the inhabitant is known to be global.
Phantom type parameter for t which represents that the locality of the inhabitant is unknown, and so must be assumed to be local.
Abstract over whether a value is global or local, with zero runtime cost, supporting mode crossing locality in the global case
('a, global) t represents a 'a that is known to be global. This type importantly mode-crosses along the locality axis, even if 'a usually does not.
('a, local) t represents a 'a whose locality is unknown. This type does not mode-cross along the locality axis, even if 'a usually does.
val hash_fold_local :
Ppx_hash_lib.Std.Hash.state ->
local ->
Ppx_hash_lib.Std.Hash.stateval hash_local : local -> Ppx_hash_lib.Std.Hash.hash_valueval sexp_of_local : local -> Sexplib0.Sexp.tval local_sexp_grammar : local Sexplib0.Sexp_grammar.t @@ portableval hash_fold_global :
Ppx_hash_lib.Std.Hash.state ->
global ->
Ppx_hash_lib.Std.Hash.stateval hash_global : global -> Ppx_hash_lib.Std.Hash.hash_valueval sexp_of_global : global -> Sexplib0.Sexp.tval global_sexp_grammar : global Sexplib0.Sexp_grammar.t @@ portableinclude Ppx_compare_lib.Comparable.S2
with type (+'a, 'locality) t := ('a, 'locality) tinclude Ppx_compare_lib.Comparable.S2__local
with type (+'a, 'locality) t := ('a, 'locality) tinclude Ppx_compare_lib.Equal.S2
with type (+'a, 'locality) t := ('a, 'locality) tinclude Ppx_compare_lib.Equal.S2__local
with type (+'a, 'locality) t := ('a, 'locality) tinclude Ppx_hash_lib.Hashable.S2_any
with type (+'a, 'locality) t := ('a, 'locality) tval hash_fold_t :
'a Ppx_hash_lib.hash_fold ->
'b Ppx_hash_lib.hash_fold ->
('a, 'b) t Ppx_hash_lib.hash_foldval sexp_of_t :
('a -> Sexplib0.Sexp.t) ->
('locality -> Sexplib0.Sexp.t) ->
('a, 'locality) t ->
Sexplib0.Sexp.tval t_sexp_grammar :
'a 'locality. 'a Sexplib0.Sexp_grammar.t ->
'locality Sexplib0.Sexp_grammar.t ->
('a, 'locality) t Sexplib0.Sexp_grammar.t @@ portableval wrap : 'a -> ('a, _) tCreate a global wrapper. Can have any phantom type.
val unwrap : ('a, _) t -> 'aUnwrap a global wrapper. When the wrapper is global, the contents are too.
val unwrap_local : ('a, _) t @ local -> 'a @ localUnwrap local contents. Global or local contents can be unwrapped as local.
Convert phantom type of a wrapper to local.