Ast.Rust
val pp_safety_kind :
Ppx_deriving_runtime.Format.formatter ->
safety_kind ->
Ppx_deriving_runtime.unit
val show_safety_kind : safety_kind -> Ppx_deriving_runtime.string
val equal_safety_kind : safety_kind -> safety_kind -> Ppx_deriving_runtime.bool
val safety_kind_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> safety_kind
val yojson_of_safety_kind : safety_kind -> Ppx_yojson_conv_lib.Yojson.Safe.t
val compare_safety_kind : safety_kind -> safety_kind -> Prelude.int
val safety_kind_of_sexp : Sexplib0.Sexp.t -> safety_kind
val sexp_of_safety_kind : safety_kind -> Sexplib0.Sexp.t
val hash_fold_safety_kind :
Ppx_hash_lib.Std.Hash.state ->
safety_kind ->
Ppx_hash_lib.Std.Hash.state
val hash_safety_kind : safety_kind -> Ppx_hash_lib.Std.Hash.hash_value
type borrow_kind = Make(Features.Rust).borrow_kind =
| Unique
| Mut of Features.Rust.mutable_reference
val pp_borrow_kind :
Ppx_deriving_runtime.Format.formatter ->
borrow_kind ->
Ppx_deriving_runtime.unit
val show_borrow_kind : borrow_kind -> Ppx_deriving_runtime.string
val equal_borrow_kind : borrow_kind -> borrow_kind -> Ppx_deriving_runtime.bool
val borrow_kind_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> borrow_kind
val yojson_of_borrow_kind : borrow_kind -> Ppx_yojson_conv_lib.Yojson.Safe.t
val compare_borrow_kind : borrow_kind -> borrow_kind -> Prelude.int
val borrow_kind_of_sexp : Sexplib0.Sexp.t -> borrow_kind
val sexp_of_borrow_kind : borrow_kind -> Sexplib0.Sexp.t
val hash_fold_borrow_kind :
Ppx_hash_lib.Std.Hash.state ->
borrow_kind ->
Ppx_hash_lib.Std.Hash.state
val hash_borrow_kind : borrow_kind -> Ppx_hash_lib.Std.Hash.hash_value
type binding_mode = Make(Features.Rust).binding_mode =
| ByValue
| ByRef of borrow_kind * Features.Rust.reference
val pp_binding_mode :
Ppx_deriving_runtime.Format.formatter ->
binding_mode ->
Ppx_deriving_runtime.unit
val show_binding_mode : binding_mode -> Ppx_deriving_runtime.string
val equal_binding_mode :
binding_mode ->
binding_mode ->
Ppx_deriving_runtime.bool
val binding_mode_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> binding_mode
val yojson_of_binding_mode : binding_mode -> Ppx_yojson_conv_lib.Yojson.Safe.t
val compare_binding_mode : binding_mode -> binding_mode -> Prelude.int
val binding_mode_of_sexp : Sexplib0.Sexp.t -> binding_mode
val sexp_of_binding_mode : binding_mode -> Sexplib0.Sexp.t
val hash_fold_binding_mode :
Ppx_hash_lib.Std.Hash.state ->
binding_mode ->
Ppx_hash_lib.Std.Hash.state
val hash_binding_mode : binding_mode -> Ppx_hash_lib.Std.Hash.hash_value
type ty = Make(Features.Rust).ty =
| TBool
| TChar
| TInt of int_kind
| TFloat of float_kind
| TStr
| TApp of {
ident : global_ident;
args : generic_value Prelude.list;
}
| TArray of {
}
| TSlice of {
witness : Features.Rust.slice;
ty : ty;
}
| TRawPointer of {
witness : Features.Rust.raw_pointer;
}
| TRef of {
witness : Features.Rust.reference;
region : todo;
typ : ty;
mut : Features.Rust.mutable_reference mutability;
}
| TParam of local_ident
| TArrow of ty Prelude.list * ty
| TAssociatedType of {
impl : impl_expr;
item : concrete_ident;
}
| TOpaque of concrete_ident
| TDyn of {
witness : Features.Rust.dyn;
goals : dyn_trait_goal Prelude.list;
}
and generic_value = Make(Features.Rust).generic_value =
| GLifetime of {
lt : todo;
witness : Features.Rust.lifetime;
}
| GType of ty
| GConst of expr
and impl_expr_kind = Make(Features.Rust).impl_expr_kind =
| Self
| Concrete of trait_goal
| LocalBound of {
id : Prelude.string;
}
| Parent of {
impl : impl_expr;
ident : impl_ident;
}
| Projection of {
impl : impl_expr;
item : concrete_ident;
ident : impl_ident;
}
| ImplApp of {
impl : impl_expr;
args : impl_expr Prelude.list;
}
| Dyn
| Builtin of trait_goal
and trait_goal = Make(Features.Rust).trait_goal = {
trait : concrete_ident;
args : generic_value Prelude.list;
}
A fully applied trait: Foo<SomeTy, T0, ..., Tn>
(or `SomeTy: Foo<T0, ..., Tn>`). An `impl_expr` "inhabits" a `trait_goal`.
and dyn_trait_goal = Make(Features.Rust).dyn_trait_goal = {
trait : concrete_ident;
non_self_args : generic_value Prelude.list;
}
A dyn trait: Foo<_, T0, ..., Tn>
. The generic arguments are known but the actual type implementing the trait is known only dynamically.
An impl identifier {goal; name}
can be:
name
that inhabits goal
.i
: i.name
inhabits goal
. This corresponds to parent bounds or associated type bounds.name
that inhabits goal
.and projection_predicate = Make(Features.Rust).projection_predicate = {
impl : impl_expr;
assoc_item : concrete_ident;
typ : ty;
}
Expresses a constraints over an associated type. For instance:
fn f<T : Foo<S = String>>(...)
^^^^^^^^^^
(provided the trait `Foo` has an associated type `S`).
and pat' = Make(Features.Rust).pat' =
| PWild
| PAscription of {
}
| PConstruct of {
constructor : global_ident;
is_record : Prelude.bool;
is_struct : Prelude.bool;
fields : field_pat Prelude.list;
}
| POr of {
subpats : pat Prelude.list;
}
| PArray of {
args : pat Prelude.list;
}
| PDeref of {
subpat : pat;
witness : Features.Rust.reference;
}
| PConstant of {
lit : literal;
}
| PBinding of {
mut : Features.Rust.mutable_variable mutability;
mode : binding_mode;
var : local_ident;
typ : ty;
subpat : (pat * Features.Rust.as_pattern) Prelude.option;
}
and expr' = Make(Features.Rust).expr' =
| If of {
cond : expr;
then_ : expr;
else_ : expr Prelude.option;
}
| App of {
f : expr;
args : expr Prelude.list;
generic_args : generic_value Prelude.list;
bounds_impls : impl_expr Prelude.list;
trait : (impl_expr * generic_value Prelude.list) Prelude.option;
}
| Literal of literal
| Array of expr Prelude.list
| Construct of {
constructor : global_ident;
is_record : Prelude.bool;
is_struct : Prelude.bool;
fields : (global_ident * expr) Prelude.list;
base : (expr * Features.Rust.construct_base) Prelude.option;
}
| Match of {
scrutinee : expr;
arms : arm Prelude.list;
}
| Let of {
monadic : (supported_monads * Features.Rust.monadic_binding) Prelude.option;
lhs : pat;
rhs : expr;
body : expr;
}
| Block of {
e : expr;
safety_mode : safety_kind;
witness : Features.Rust.block;
}
| LocalVar of local_ident
| GlobalVar of global_ident
| Ascription of {
}
| MacroInvokation of {
macro : global_ident;
args : Prelude.string;
witness : Features.Rust.macro;
}
| Assign of {
lhs : lhs;
e : expr;
witness : Features.Rust.mutable_variable;
}
| Loop of {
body : expr;
kind : loop_kind;
state : loop_state Prelude.option;
control_flow : (cf_kind * Features.Rust.fold_like_loop) Prelude.option;
label : Prelude.string Prelude.option;
witness : Features.Rust.loop;
}
| Break of {
e : expr;
acc : (expr * Features.Rust.state_passing_loop) Prelude.option;
label : Prelude.string Prelude.option;
witness : Features.Rust.break * Features.Rust.loop;
}
| Return of {
e : expr;
witness : Features.Rust.early_exit;
}
| QuestionMark of {
e : expr;
return_typ : ty;
witness : Features.Rust.question_mark;
}
The expression `e?`. In opposition to Rust, no implicit coercion is applied on the (potential) error payload of `e`. Coercion should be made explicit within `e`.
*)| Continue of {
acc : (expr * Features.Rust.state_passing_loop) Prelude.option;
label : Prelude.string Prelude.option;
witness : Features.Rust.continue * Features.Rust.loop;
}
| Borrow of {
kind : borrow_kind;
e : expr;
witness : Features.Rust.reference;
}
| AddressOf of {
mut : Features.Rust.mutable_pointer mutability;
e : expr;
witness : Features.Rust.raw_pointer;
}
| Closure of {
params : pat Prelude.list;
body : expr;
captures : expr Prelude.list;
}
| EffectAction of {
action : Features.Rust.monadic_action;
argument : expr;
}
| Quote of quote
A quotation is an inlined piece of backend code interleaved with Rust code
*)and quote = Make(Features.Rust).quote = {
contents : [ `Expr of expr
| `Pat of pat
| `Typ of ty
| `Verbatim of Prelude.string ]
Prelude.list;
witness : Features.Rust.quote;
}
and supported_monads = Make(Features.Rust).supported_monads =
and loop_kind = Make(Features.Rust).loop_kind =
| UnconditionalLoop
| WhileLoop of {
condition : expr;
witness : Features.Rust.while_loop;
}
| ForLoop of {
pat : pat;
it : expr;
witness : Features.Rust.for_loop;
}
| ForIndexLoop of {
start : expr;
end_ : expr;
var : local_ident;
var_typ : ty;
witness : Features.Rust.for_index_loop;
}
and loop_state = Make(Features.Rust).loop_state = {
init : expr;
bpat : pat;
witness : Features.Rust.state_passing_loop;
}
and lhs = Make(Features.Rust).lhs =
| LhsLocalVar of {
var : Local_ident.t;
typ : ty;
}
| LhsArbitraryExpr of {
e : expr;
witness : Features.Rust.arbitrary_lhs;
}
| LhsFieldAccessor of {
e : lhs;
typ : ty;
field : global_ident;
witness : Features.Rust.nontrivial_lhs;
}
| LhsArrayAccessor of {
e : lhs;
typ : ty;
index : expr;
witness : Features.Rust.nontrivial_lhs;
}
and guard' = Make(Features.Rust).guard' =
| IfLet of {
lhs : pat;
rhs : expr;
witness : Features.Rust.match_guard;
}
val pp_ty :
Ppx_deriving_runtime.Format.formatter ->
ty ->
Ppx_deriving_runtime.unit
val show_ty : ty -> Ppx_deriving_runtime.string
val pp_generic_value :
Ppx_deriving_runtime.Format.formatter ->
generic_value ->
Ppx_deriving_runtime.unit
val show_generic_value : generic_value -> Ppx_deriving_runtime.string
val pp_impl_expr :
Ppx_deriving_runtime.Format.formatter ->
impl_expr ->
Ppx_deriving_runtime.unit
val show_impl_expr : impl_expr -> Ppx_deriving_runtime.string
val pp_impl_expr_kind :
Ppx_deriving_runtime.Format.formatter ->
impl_expr_kind ->
Ppx_deriving_runtime.unit
val show_impl_expr_kind : impl_expr_kind -> Ppx_deriving_runtime.string
val pp_trait_goal :
Ppx_deriving_runtime.Format.formatter ->
trait_goal ->
Ppx_deriving_runtime.unit
val show_trait_goal : trait_goal -> Ppx_deriving_runtime.string
val pp_dyn_trait_goal :
Ppx_deriving_runtime.Format.formatter ->
dyn_trait_goal ->
Ppx_deriving_runtime.unit
val show_dyn_trait_goal : dyn_trait_goal -> Ppx_deriving_runtime.string
val pp_impl_ident :
Ppx_deriving_runtime.Format.formatter ->
impl_ident ->
Ppx_deriving_runtime.unit
val show_impl_ident : impl_ident -> Ppx_deriving_runtime.string
val pp_projection_predicate :
Ppx_deriving_runtime.Format.formatter ->
projection_predicate ->
Ppx_deriving_runtime.unit
val show_projection_predicate :
projection_predicate ->
Ppx_deriving_runtime.string
val pp_pat' :
Ppx_deriving_runtime.Format.formatter ->
pat' ->
Ppx_deriving_runtime.unit
val show_pat' : pat' -> Ppx_deriving_runtime.string
val pp_pat :
Ppx_deriving_runtime.Format.formatter ->
pat ->
Ppx_deriving_runtime.unit
val show_pat : pat -> Ppx_deriving_runtime.string
val pp_field_pat :
Ppx_deriving_runtime.Format.formatter ->
field_pat ->
Ppx_deriving_runtime.unit
val show_field_pat : field_pat -> Ppx_deriving_runtime.string
val pp_cf_kind :
Ppx_deriving_runtime.Format.formatter ->
cf_kind ->
Ppx_deriving_runtime.unit
val show_cf_kind : cf_kind -> Ppx_deriving_runtime.string
val pp_expr' :
Ppx_deriving_runtime.Format.formatter ->
expr' ->
Ppx_deriving_runtime.unit
val show_expr' : expr' -> Ppx_deriving_runtime.string
val pp_expr :
Ppx_deriving_runtime.Format.formatter ->
expr ->
Ppx_deriving_runtime.unit
val show_expr : expr -> Ppx_deriving_runtime.string
val pp_quote :
Ppx_deriving_runtime.Format.formatter ->
quote ->
Ppx_deriving_runtime.unit
val show_quote : quote -> Ppx_deriving_runtime.string
val pp_supported_monads :
Ppx_deriving_runtime.Format.formatter ->
supported_monads ->
Ppx_deriving_runtime.unit
val show_supported_monads : supported_monads -> Ppx_deriving_runtime.string
val pp_loop_kind :
Ppx_deriving_runtime.Format.formatter ->
loop_kind ->
Ppx_deriving_runtime.unit
val show_loop_kind : loop_kind -> Ppx_deriving_runtime.string
val pp_loop_state :
Ppx_deriving_runtime.Format.formatter ->
loop_state ->
Ppx_deriving_runtime.unit
val show_loop_state : loop_state -> Ppx_deriving_runtime.string
val pp_lhs :
Ppx_deriving_runtime.Format.formatter ->
lhs ->
Ppx_deriving_runtime.unit
val show_lhs : lhs -> Ppx_deriving_runtime.string
val pp_guard :
Ppx_deriving_runtime.Format.formatter ->
guard ->
Ppx_deriving_runtime.unit
val show_guard : guard -> Ppx_deriving_runtime.string
val pp_guard' :
Ppx_deriving_runtime.Format.formatter ->
guard' ->
Ppx_deriving_runtime.unit
val show_guard' : guard' -> Ppx_deriving_runtime.string
val pp_arm' :
Ppx_deriving_runtime.Format.formatter ->
arm' ->
Ppx_deriving_runtime.unit
val show_arm' : arm' -> Ppx_deriving_runtime.string
val pp_arm :
Ppx_deriving_runtime.Format.formatter ->
arm ->
Ppx_deriving_runtime.unit
val show_arm : arm -> Ppx_deriving_runtime.string
val equal_generic_value :
generic_value ->
generic_value ->
Ppx_deriving_runtime.bool
val equal_impl_expr_kind :
impl_expr_kind ->
impl_expr_kind ->
Ppx_deriving_runtime.bool
val equal_trait_goal : trait_goal -> trait_goal -> Ppx_deriving_runtime.bool
val equal_dyn_trait_goal :
dyn_trait_goal ->
dyn_trait_goal ->
Ppx_deriving_runtime.bool
val equal_impl_ident : impl_ident -> impl_ident -> Ppx_deriving_runtime.bool
val equal_projection_predicate :
projection_predicate ->
projection_predicate ->
Ppx_deriving_runtime.bool
val equal_supported_monads :
supported_monads ->
supported_monads ->
Ppx_deriving_runtime.bool
val equal_loop_state : loop_state -> loop_state -> Ppx_deriving_runtime.bool
val ty_of_yojson : Yojson.Safe.t -> ty
val generic_value_of_yojson : Yojson.Safe.t -> generic_value
val impl_expr_of_yojson : Yojson.Safe.t -> impl_expr
val impl_expr_kind_of_yojson :
Ppx_yojson_conv_lib.Yojson.Safe.t ->
impl_expr_kind
val trait_goal_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> trait_goal
val dyn_trait_goal_of_yojson : Yojson.Safe.t -> dyn_trait_goal
val impl_ident_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> impl_ident
val projection_predicate_of_yojson :
Ppx_yojson_conv_lib.Yojson.Safe.t ->
projection_predicate
val pat'_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> pat'
val pat_of_yojson : Yojson.Safe.t -> pat
val field_pat_of_yojson : Yojson.Safe.t -> field_pat
val cf_kind_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> cf_kind
val expr'_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> expr'
val expr_of_yojson : Yojson.Safe.t -> expr
val quote_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> quote
val supported_monads_of_yojson : Yojson.Safe.t -> supported_monads
val loop_kind_of_yojson : Yojson.Safe.t -> loop_kind
val loop_state_of_yojson : Yojson.Safe.t -> loop_state
val lhs_of_yojson : Yojson.Safe.t -> lhs
val guard_of_yojson : Yojson.Safe.t -> guard
val guard'_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> guard'
val arm'_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> arm'
val arm_of_yojson : Yojson.Safe.t -> arm
val yojson_of_ty : ty -> Yojson.Safe.t
val yojson_of_generic_value : generic_value -> Yojson.Safe.t
val yojson_of_impl_expr : impl_expr -> Yojson.Safe.t
val yojson_of_impl_expr_kind :
impl_expr_kind ->
Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_trait_goal : trait_goal -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_dyn_trait_goal : dyn_trait_goal -> Yojson.Safe.t
val yojson_of_impl_ident : impl_ident -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_projection_predicate :
projection_predicate ->
Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_pat' : pat' -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_pat : pat -> Yojson.Safe.t
val yojson_of_field_pat : field_pat -> Yojson.Safe.t
val yojson_of_cf_kind : cf_kind -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_expr' : expr' -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_expr : expr -> Yojson.Safe.t
val yojson_of_quote : quote -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_supported_monads :
supported_monads ->
Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_loop_kind : loop_kind -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_loop_state : loop_state -> Yojson.Safe.t
val yojson_of_lhs : lhs -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_guard : guard -> Yojson.Safe.t
val yojson_of_guard' : guard' -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_arm' : arm' -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_arm : arm -> Yojson.Safe.t
val compare_ty : ty -> ty -> Prelude.int
val compare_generic_value : generic_value -> generic_value -> Prelude.int
val compare_impl_expr : impl_expr -> impl_expr -> Prelude.int
val compare_impl_expr_kind : impl_expr_kind -> impl_expr_kind -> Prelude.int
val compare_trait_goal : trait_goal -> trait_goal -> Prelude.int
val compare_dyn_trait_goal : dyn_trait_goal -> dyn_trait_goal -> Prelude.int
val compare_impl_ident : impl_ident -> impl_ident -> Prelude.int
val compare_projection_predicate :
projection_predicate ->
projection_predicate ->
Prelude.int
val compare_pat' : pat' -> pat' -> Prelude.int
val compare_pat : pat -> pat -> Prelude.int
val compare_field_pat : field_pat -> field_pat -> Prelude.int
val compare_cf_kind : cf_kind -> cf_kind -> Prelude.int
val compare_expr' : expr' -> expr' -> Prelude.int
val compare_expr : expr -> expr -> Prelude.int
val compare_quote : quote -> quote -> Prelude.int
val compare_supported_monads :
supported_monads ->
supported_monads ->
Prelude.int
val compare_loop_kind : loop_kind -> loop_kind -> Prelude.int
val compare_loop_state : loop_state -> loop_state -> Prelude.int
val compare_lhs : lhs -> lhs -> Prelude.int
val compare_guard : guard -> guard -> Prelude.int
val compare_guard' : guard' -> guard' -> Prelude.int
val compare_arm' : arm' -> arm' -> Prelude.int
val compare_arm : arm -> arm -> Prelude.int
val ty_of_sexp : Sexplib0__.Sexp.t -> ty
val generic_value_of_sexp : Sexplib0.Sexp.t -> generic_value
val impl_expr_of_sexp : Sexplib0.Sexp.t -> impl_expr
val impl_expr_kind_of_sexp : Sexplib0__.Sexp.t -> impl_expr_kind
val trait_goal_of_sexp : Sexplib0__.Sexp.t -> trait_goal
val dyn_trait_goal_of_sexp : Sexplib0.Sexp.t -> dyn_trait_goal
val impl_ident_of_sexp : Sexplib0__.Sexp.t -> impl_ident
val projection_predicate_of_sexp : Sexplib0.Sexp.t -> projection_predicate
val pat'_of_sexp : Sexplib0__.Sexp.t -> pat'
val pat_of_sexp : Sexplib0__.Sexp.t -> pat
val field_pat_of_sexp : Sexplib0.Sexp.t -> field_pat
val cf_kind_of_sexp : Sexplib0.Sexp.t -> cf_kind
val expr'_of_sexp : Sexplib0__.Sexp.t -> expr'
val expr_of_sexp : Sexplib0__.Sexp.t -> expr
val quote_of_sexp : Sexplib0.Sexp.t -> quote
val supported_monads_of_sexp : Sexplib0.Sexp.t -> supported_monads
val loop_kind_of_sexp : Sexplib0__.Sexp.t -> loop_kind
val loop_state_of_sexp : Sexplib0.Sexp.t -> loop_state
val lhs_of_sexp : Sexplib0__.Sexp.t -> lhs
val guard_of_sexp : Sexplib0.Sexp.t -> guard
val guard'_of_sexp : Sexplib0__.Sexp.t -> guard'
val arm'_of_sexp : Sexplib0__.Sexp.t -> arm'
val arm_of_sexp : Sexplib0.Sexp.t -> arm
val sexp_of_ty : ty -> Sexplib0.Sexp.t
val sexp_of_generic_value : generic_value -> Sexplib0.Sexp.t
val sexp_of_impl_expr : impl_expr -> Sexplib0.Sexp.t
val sexp_of_impl_expr_kind : impl_expr_kind -> Sexplib0.Sexp.t
val sexp_of_trait_goal : trait_goal -> Sexplib0.Sexp.t
val sexp_of_dyn_trait_goal : dyn_trait_goal -> Sexplib0.Sexp.t
val sexp_of_impl_ident : impl_ident -> Sexplib0.Sexp.t
val sexp_of_projection_predicate : projection_predicate -> Sexplib0.Sexp.t
val sexp_of_pat' : pat' -> Sexplib0.Sexp.t
val sexp_of_pat : pat -> Sexplib0.Sexp.t
val sexp_of_field_pat : field_pat -> Sexplib0.Sexp.t
val sexp_of_cf_kind : cf_kind -> Sexplib0.Sexp.t
val sexp_of_expr' : expr' -> Sexplib0.Sexp.t
val sexp_of_expr : expr -> Sexplib0.Sexp.t
val sexp_of_quote : quote -> Sexplib0.Sexp.t
val sexp_of_supported_monads : supported_monads -> Sexplib0.Sexp.t
val sexp_of_loop_kind : loop_kind -> Sexplib0.Sexp.t
val sexp_of_loop_state : loop_state -> Sexplib0.Sexp.t
val sexp_of_lhs : lhs -> Sexplib0.Sexp.t
val sexp_of_guard : guard -> Sexplib0.Sexp.t
val sexp_of_guard' : guard' -> Sexplib0.Sexp.t
val sexp_of_arm' : arm' -> Sexplib0.Sexp.t
val sexp_of_arm : arm -> Sexplib0.Sexp.t
val hash_fold_ty :
Base__.Ppx_hash_lib.Std.Hash.state ->
ty ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_generic_value :
Base__.Ppx_hash_lib.Std.Hash.state ->
generic_value ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_impl_expr :
Base__.Ppx_hash_lib.Std.Hash.state ->
impl_expr ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_impl_expr_kind :
Ppx_hash_lib.Std.Hash.state ->
impl_expr_kind ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_trait_goal :
Ppx_hash_lib.Std.Hash.state ->
trait_goal ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_dyn_trait_goal :
Base__.Ppx_hash_lib.Std.Hash.state ->
dyn_trait_goal ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_impl_ident :
Ppx_hash_lib.Std.Hash.state ->
impl_ident ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_projection_predicate :
Ppx_hash_lib.Std.Hash.state ->
projection_predicate ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_pat' :
Ppx_hash_lib.Std.Hash.state ->
pat' ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_pat :
Base__.Ppx_hash_lib.Std.Hash.state ->
pat ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_field_pat :
Base__.Ppx_hash_lib.Std.Hash.state ->
field_pat ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_cf_kind :
Ppx_hash_lib.Std.Hash.state ->
cf_kind ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_expr' :
Ppx_hash_lib.Std.Hash.state ->
expr' ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_expr :
Base__.Ppx_hash_lib.Std.Hash.state ->
expr ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_quote :
Ppx_hash_lib.Std.Hash.state ->
quote ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_supported_monads :
Ppx_hash_lib.Std.Hash.state ->
supported_monads ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_loop_kind :
Ppx_hash_lib.Std.Hash.state ->
loop_kind ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_loop_state :
Base__.Ppx_hash_lib.Std.Hash.state ->
loop_state ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_lhs :
Ppx_hash_lib.Std.Hash.state ->
lhs ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_guard :
Base__.Ppx_hash_lib.Std.Hash.state ->
guard ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_guard' :
Ppx_hash_lib.Std.Hash.state ->
guard' ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_arm' :
Ppx_hash_lib.Std.Hash.state ->
arm' ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_arm :
Base__.Ppx_hash_lib.Std.Hash.state ->
arm ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_ty : ty -> Ppx_hash_lib.Std.Hash.hash_value
val hash_generic_value : generic_value -> Ppx_hash_lib.Std.Hash.hash_value
val hash_impl_expr : impl_expr -> Ppx_hash_lib.Std.Hash.hash_value
val hash_impl_expr_kind : impl_expr_kind -> Ppx_hash_lib.Std.Hash.hash_value
val hash_trait_goal : trait_goal -> Ppx_hash_lib.Std.Hash.hash_value
val hash_dyn_trait_goal : dyn_trait_goal -> Ppx_hash_lib.Std.Hash.hash_value
val hash_impl_ident : impl_ident -> Ppx_hash_lib.Std.Hash.hash_value
val hash_projection_predicate :
projection_predicate ->
Ppx_hash_lib.Std.Hash.hash_value
val hash_pat' : pat' -> Ppx_hash_lib.Std.Hash.hash_value
val hash_pat : pat -> Ppx_hash_lib.Std.Hash.hash_value
val hash_field_pat : field_pat -> Ppx_hash_lib.Std.Hash.hash_value
val hash_cf_kind : cf_kind -> Ppx_hash_lib.Std.Hash.hash_value
val hash_expr' : expr' -> Ppx_hash_lib.Std.Hash.hash_value
val hash_expr : expr -> Ppx_hash_lib.Std.Hash.hash_value
val hash_quote : quote -> Ppx_hash_lib.Std.Hash.hash_value
val hash_supported_monads :
supported_monads ->
Ppx_hash_lib.Std.Hash.hash_value
val hash_loop_kind : loop_kind -> Ppx_hash_lib.Std.Hash.hash_value
val hash_loop_state : loop_state -> Ppx_hash_lib.Std.Hash.hash_value
val hash_lhs : lhs -> Ppx_hash_lib.Std.Hash.hash_value
val hash_guard : guard -> Ppx_hash_lib.Std.Hash.hash_value
val hash_guard' : guard' -> Ppx_hash_lib.Std.Hash.hash_value
val hash_arm' : arm' -> Ppx_hash_lib.Std.Hash.hash_value
val hash_arm : arm -> Ppx_hash_lib.Std.Hash.hash_value
type generic_param = Make(Features.Rust).generic_param = {
ident : local_ident;
span : span;
attrs : attrs;
kind : generic_param_kind;
}
and generic_param_kind = Make(Features.Rust).generic_param_kind =
| GPLifetime of {
witness : Features.Rust.lifetime;
}
| GPType
| GPConst of {
typ : ty;
}
and generic_constraint = Make(Features.Rust).generic_constraint =
| GCLifetime of todo * Features.Rust.lifetime
| GCType of impl_ident
| GCProjection of projection_predicate
Trait or lifetime constraints. For instance, `A` and `B` in `fn f<T: A + B>()`.
*)val pp_generic_param :
Ppx_deriving_runtime.Format.formatter ->
generic_param ->
Ppx_deriving_runtime.unit
val show_generic_param : generic_param -> Ppx_deriving_runtime.string
val pp_generic_param_kind :
Ppx_deriving_runtime.Format.formatter ->
generic_param_kind ->
Ppx_deriving_runtime.unit
val show_generic_param_kind : generic_param_kind -> Ppx_deriving_runtime.string
val pp_generic_constraint :
Ppx_deriving_runtime.Format.formatter ->
generic_constraint ->
Ppx_deriving_runtime.unit
val show_generic_constraint : generic_constraint -> Ppx_deriving_runtime.string
val equal_generic_param :
generic_param ->
generic_param ->
Ppx_deriving_runtime.bool
val equal_generic_param_kind :
generic_param_kind ->
generic_param_kind ->
Ppx_deriving_runtime.bool
val equal_generic_constraint :
generic_constraint ->
generic_constraint ->
Ppx_deriving_runtime.bool
val generic_param_of_yojson :
Ppx_yojson_conv_lib.Yojson.Safe.t ->
generic_param
val generic_param_kind_of_yojson :
Ppx_yojson_conv_lib.Yojson.Safe.t ->
generic_param_kind
val generic_constraint_of_yojson :
Ppx_yojson_conv_lib.Yojson.Safe.t ->
generic_constraint
val yojson_of_generic_param :
generic_param ->
Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_generic_param_kind :
generic_param_kind ->
Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_generic_constraint :
generic_constraint ->
Ppx_yojson_conv_lib.Yojson.Safe.t
val compare_generic_param : generic_param -> generic_param -> Prelude.int
val compare_generic_param_kind :
generic_param_kind ->
generic_param_kind ->
Prelude.int
val compare_generic_constraint :
generic_constraint ->
generic_constraint ->
Prelude.int
val generic_param_of_sexp : Sexplib0.Sexp.t -> generic_param
val generic_param_kind_of_sexp : Sexplib0__.Sexp.t -> generic_param_kind
val generic_constraint_of_sexp : Sexplib0.Sexp.t -> generic_constraint
val sexp_of_generic_param : generic_param -> Sexplib0.Sexp.t
val sexp_of_generic_param_kind : generic_param_kind -> Sexplib0.Sexp.t
val sexp_of_generic_constraint : generic_constraint -> Sexplib0.Sexp.t
val hash_fold_generic_param :
Ppx_hash_lib.Std.Hash.state ->
generic_param ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_generic_param_kind :
Ppx_hash_lib.Std.Hash.state ->
generic_param_kind ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_generic_constraint :
Ppx_hash_lib.Std.Hash.state ->
generic_constraint ->
Ppx_hash_lib.Std.Hash.state
val hash_generic_param : generic_param -> Ppx_hash_lib.Std.Hash.hash_value
val hash_generic_param_kind :
generic_param_kind ->
Ppx_hash_lib.Std.Hash.hash_value
val hash_generic_constraint :
generic_constraint ->
Ppx_hash_lib.Std.Hash.hash_value
type param = Make(Features.Rust).param = {
pat : pat;
typ : ty;
typ_span : span Prelude.option;
attrs : attrs;
}
and generics = Make(Features.Rust).generics = {
params : generic_param Prelude.list;
constraints : generic_constraint Prelude.list;
}
and variant = Make(Features.Rust).variant = {
name : concrete_ident;
arguments : (concrete_ident * ty * attrs) Prelude.list;
is_record : Prelude.bool;
attrs : attrs;
}
and item' = Make(Features.Rust).item' =
| Fn of {
name : concrete_ident;
generics : generics;
body : expr;
params : param Prelude.list;
safety : safety_kind;
}
| TyAlias of {
name : concrete_ident;
generics : generics;
ty : ty;
}
| Type of {
name : concrete_ident;
generics : generics;
variants : variant Prelude.list;
is_struct : Prelude.bool;
}
| IMacroInvokation of {
macro : concrete_ident;
argument : Prelude.string;
span : span;
witness : Features.Rust.macro;
}
| Trait of {
name : concrete_ident;
generics : generics;
items : trait_item Prelude.list;
safety : safety_kind;
}
| Impl of {
generics : generics;
self_ty : ty;
of_trait : concrete_ident * generic_value Prelude.list;
items : impl_item Prelude.list;
parent_bounds : (impl_expr * impl_ident) Prelude.list;
safety : safety_kind;
}
| Alias of {
name : concrete_ident;
item : concrete_ident;
}
`Alias name; item
` is basically a `use <item> as _;` where `name` is the renamed ident.
| Use of {
path : Prelude.string Prelude.list;
is_external : Prelude.bool;
rename : Prelude.string Prelude.option;
}
| Quote of {
quote : quote;
origin : item_quote_origin;
}
| HaxError of Prelude.string
| NotImplementedYet
and impl_item' = Make(Features.Rust).impl_item' =
| IIType of {
typ : ty;
parent_bounds : (impl_expr * impl_ident) Prelude.list;
}
| IIFn of {
body : expr;
params : param Prelude.list;
}
and impl_item = Make(Features.Rust).impl_item = {
ii_span : span;
ii_generics : generics;
ii_v : impl_item';
ii_ident : concrete_ident;
ii_attrs : attrs;
}
and trait_item' = Make(Features.Rust).trait_item' =
| TIType of impl_ident Prelude.list
| TIFn of ty
| TIDefault of {
params : param Prelude.list;
body : expr;
witness : Features.Rust.trait_item_default;
}
and trait_item = Make(Features.Rust).trait_item = {
ti_span : span;
ti_generics : generics;
ti_v : trait_item';
ti_ident : concrete_ident;
ti_attrs : attrs;
}
val pp_param :
Ppx_deriving_runtime.Format.formatter ->
param ->
Ppx_deriving_runtime.unit
val show_param : param -> Ppx_deriving_runtime.string
val pp_generics :
Ppx_deriving_runtime.Format.formatter ->
generics ->
Ppx_deriving_runtime.unit
val show_generics : generics -> Ppx_deriving_runtime.string
val pp_variant :
Ppx_deriving_runtime.Format.formatter ->
variant ->
Ppx_deriving_runtime.unit
val show_variant : variant -> Ppx_deriving_runtime.string
val pp_item' :
Ppx_deriving_runtime.Format.formatter ->
item' ->
Ppx_deriving_runtime.unit
val show_item' : item' -> Ppx_deriving_runtime.string
val pp_item :
Ppx_deriving_runtime.Format.formatter ->
item ->
Ppx_deriving_runtime.unit
val show_item : item -> Ppx_deriving_runtime.string
val pp_impl_item' :
Ppx_deriving_runtime.Format.formatter ->
impl_item' ->
Ppx_deriving_runtime.unit
val show_impl_item' : impl_item' -> Ppx_deriving_runtime.string
val pp_impl_item :
Ppx_deriving_runtime.Format.formatter ->
impl_item ->
Ppx_deriving_runtime.unit
val show_impl_item : impl_item -> Ppx_deriving_runtime.string
val pp_trait_item' :
Ppx_deriving_runtime.Format.formatter ->
trait_item' ->
Ppx_deriving_runtime.unit
val show_trait_item' : trait_item' -> Ppx_deriving_runtime.string
val pp_trait_item :
Ppx_deriving_runtime.Format.formatter ->
trait_item ->
Ppx_deriving_runtime.unit
val show_trait_item : trait_item -> Ppx_deriving_runtime.string
val equal_impl_item' : impl_item' -> impl_item' -> Ppx_deriving_runtime.bool
val equal_trait_item' : trait_item' -> trait_item' -> Ppx_deriving_runtime.bool
val equal_trait_item : trait_item -> trait_item -> Ppx_deriving_runtime.bool
val param_of_yojson : Yojson.Safe.t -> param
val generics_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> generics
val variant_of_yojson : Yojson.Safe.t -> variant
val item'_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> item'
val item_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> item
val impl_item'_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> impl_item'
val impl_item_of_yojson : Yojson.Safe.t -> impl_item
val trait_item'_of_yojson : Ppx_yojson_conv_lib.Yojson.Safe.t -> trait_item'
val trait_item_of_yojson : Yojson.Safe.t -> trait_item
val yojson_of_param : param -> Yojson.Safe.t
val yojson_of_generics : generics -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_variant : variant -> Yojson.Safe.t
val yojson_of_item' : item' -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_item : item -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_impl_item' : impl_item' -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_impl_item : impl_item -> Yojson.Safe.t
val yojson_of_trait_item' : trait_item' -> Ppx_yojson_conv_lib.Yojson.Safe.t
val yojson_of_trait_item : trait_item -> Yojson.Safe.t
val compare_param : param -> param -> Prelude.int
val compare_generics : generics -> generics -> Prelude.int
val compare_variant : variant -> variant -> Prelude.int
val compare_item' : item' -> item' -> Prelude.int
val compare_item : item -> item -> Prelude.int
val compare_impl_item' : impl_item' -> impl_item' -> Prelude.int
val compare_impl_item : impl_item -> impl_item -> Prelude.int
val compare_trait_item' : trait_item' -> trait_item' -> Prelude.int
val compare_trait_item : trait_item -> trait_item -> Prelude.int
val param_of_sexp : Sexplib0.Sexp.t -> param
val generics_of_sexp : Sexplib0__.Sexp.t -> generics
val variant_of_sexp : Sexplib0.Sexp.t -> variant
val item'_of_sexp : Sexplib0__.Sexp.t -> item'
val item_of_sexp : Sexplib0.Sexp.t -> item
val impl_item'_of_sexp : Sexplib0__.Sexp.t -> impl_item'
val impl_item_of_sexp : Sexplib0.Sexp.t -> impl_item
val trait_item'_of_sexp : Sexplib0__.Sexp.t -> trait_item'
val trait_item_of_sexp : Sexplib0.Sexp.t -> trait_item
val sexp_of_param : param -> Sexplib0.Sexp.t
val sexp_of_generics : generics -> Sexplib0.Sexp.t
val sexp_of_variant : variant -> Sexplib0.Sexp.t
val sexp_of_item' : item' -> Sexplib0.Sexp.t
val sexp_of_item : item -> Sexplib0.Sexp.t
val sexp_of_impl_item' : impl_item' -> Sexplib0.Sexp.t
val sexp_of_impl_item : impl_item -> Sexplib0.Sexp.t
val sexp_of_trait_item' : trait_item' -> Sexplib0.Sexp.t
val sexp_of_trait_item : trait_item -> Sexplib0.Sexp.t
val hash_fold_param :
Base__.Ppx_hash_lib.Std.Hash.state ->
param ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_generics :
Ppx_hash_lib.Std.Hash.state ->
generics ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_variant :
Base__.Ppx_hash_lib.Std.Hash.state ->
variant ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_item' :
Ppx_hash_lib.Std.Hash.state ->
item' ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_item :
Ppx_hash_lib.Std.Hash.state ->
item ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_impl_item' :
Ppx_hash_lib.Std.Hash.state ->
impl_item' ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_impl_item :
Base__.Ppx_hash_lib.Std.Hash.state ->
impl_item ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_fold_trait_item' :
Ppx_hash_lib.Std.Hash.state ->
trait_item' ->
Ppx_hash_lib.Std.Hash.state
val hash_fold_trait_item :
Base__.Ppx_hash_lib.Std.Hash.state ->
trait_item ->
Base__.Ppx_hash_lib.Std.Hash.state
val hash_param : param -> Ppx_hash_lib.Std.Hash.hash_value
val hash_generics : generics -> Ppx_hash_lib.Std.Hash.hash_value
val hash_variant : variant -> Ppx_hash_lib.Std.Hash.hash_value
val hash_item' : item' -> Ppx_hash_lib.Std.Hash.hash_value
val hash_item : item -> Ppx_hash_lib.Std.Hash.hash_value
val hash_impl_item' : impl_item' -> Ppx_hash_lib.Std.Hash.hash_value
val hash_impl_item : impl_item -> Ppx_hash_lib.Std.Hash.hash_value
val hash_trait_item' : trait_item' -> Ppx_hash_lib.Std.Hash.hash_value
val hash_trait_item : trait_item -> Ppx_hash_lib.Std.Hash.hash_value
type modul = item Prelude.list
val make_hax_error_item : span -> Concrete_ident.t -> Prelude.string -> item