package ppxlib

  1. Overview
  2. Docs
Standard infrastructure for ppx rewriters

Install

Dune Dependency

Authors

Maintainers

Sources

ppxlib-0.35.0.tbz
sha256=d9d959fc9f84260487e45684dc741898a92fc5506b61a7f5cac65d21832db925
sha512=e428b1e3b89261c7efdaa18016264d1afbf067cb9b0d41124b04796c2487ac7ca8ee9a24a60d56f20d1774cb44aaa9ecf1512f17455812ba8d62d4ef93616ee7

doc/ppxlib/Ppxlib/Extension/V3/index.html

Module Extension.V3Source

Sourcetype nonrec t = t
Sourceval declare : string -> 'context Context.t -> (Astlib.Ast_500.Parsetree.payload, 'a, 'context) Ast_pattern.t -> (ctxt:Expansion_context.Extension.t -> 'a) -> t
Sourceval declare_inline : string -> 'context Context.t -> (Astlib.Ast_500.Parsetree.payload, 'a, 'context list) Ast_pattern.t -> (ctxt:Expansion_context.Extension.t -> 'a) -> t
Sourceval declare_with_path_arg : string -> 'context Context.t -> (Astlib.Ast_500.Parsetree.payload, 'a, 'context) Ast_pattern.t -> (ctxt:Expansion_context.Extension.t -> arg:Longident.t Ppxlib_ast.Asttypes.loc option -> 'a) -> t

Same as declare except that the extension name takes an additional path argument. The path is the part of the name that start with a capitalized component. For instance in the following, the extension "map" would receive the path argument Foo.Bar:

  let%map.Foo.Bar x = 1 in
  ...
Sourceval declare_inline_with_path_arg : string -> 'context Context.t -> (Astlib.Ast_500.Parsetree.payload, 'a, 'context list) Ast_pattern.t -> (ctxt:Expansion_context.Extension.t -> arg:Longident.t Ppxlib_ast.Asttypes.loc option -> 'a) -> t
OCaml

Innovation. Community. Security.