(* File: pa_sexp_conv.ml Copyright (C) 2005- Jane Street Holding, LLC Author: Markus Mottl email: mmottl@janestcapital.com WWW: http://www.janestcapital.com/ocaml This file is derived from file "pa_tywith.ml" of version 0.45 of the library "Tywith". Tywith is Copyright (C) 2004, 2005 by Martin Sandin This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *) (** Pa_sexp_conv: Preprocessing Module for Automated S-expression Conversions *) (** {6 Generator registration} *) val add_generator : string -> (MLast.type_decl -> (MLast.patt * MLast.expr) list * MLast.type_decl list) -> unit (** [add_generator name gen] adds the code generator [gen], which must map type declarations to a pair [(matchings, type_decls)]. The matchings will lead to function definitions. *) val rem_generator : string -> unit (** [rem_generator name] removes the code generator named [name]. *)