package tyxml-syntax

  1. Overview
  2. Docs
val find : ('a -> bool) -> 'a list -> 'a option

Similar to List.find, but evaluates to an option instead of raising Not_found.

Markup language

type lang =
  1. | Html
  2. | Svg
val lang : lang -> string
val implementation : lang -> string
val set_implementation : lang -> string -> unit
type name = lang * string
val make : loc:Ppxlib.Location.t -> lang -> string -> Ppxlib.expression

Expression helpers.

val float : Ppxlib.Location.t -> float -> Ppxlib.expression
val string : Ppxlib.Location.t -> string -> Ppxlib.expression

wrap implementation loc e creates a parse tree for implementation.Xml.W.return e.

type 'a value =
  1. | Val of 'a
  2. | Antiquot of Ppxlib.expression
val map_value : ('a -> 'b) -> 'a value -> 'b value
val value : 'a -> 'a value
val antiquot : Ppxlib.expression -> _ value
val list_wrap_value : lang -> Ppxlib.Location.t -> Ppxlib.expression value list -> Ppxlib.expression
val error : Ppxlib.Location.t -> ('b, Format.formatter, unit, 'a) format4 -> 'b
val txt : loc:Ppxlib.Location.t -> lang:lang -> string -> Ppxlib.expression
OCaml

Innovation. Community. Security.