Commit 1cc3c09f authored by POTTIER Francois's avatar POTTIER Francois

Isolate [VisitorsPlugin].

parent 071269c0
......@@ -6,6 +6,7 @@ open Parsetree
open Ast_helper
open Ast_convenience
open Ppx_deriving
open VisitorsPlugin
open VisitorsAnalysis
open VisitorsGeneration
open VisitorsSettings
......
......@@ -2,6 +2,7 @@ open Longident
open Asttypes
open Parsetree
open Ppx_deriving
open VisitorsPlugin
(* This module offers helper functions for abstract syntax tree analysis. *)
......@@ -82,7 +83,7 @@ let rec is_local (decls : type_declaration list) (tycon : tycon) : tyvar list op
We could support this form, but it makes life slightly simpler
to disallow it. It is usually used only in GADTs anyway. *)
raise_errorf ~loc:ty.ptyp_loc
"visitors: every formal type parameter should be named."
"%s: every formal type parameter should be named." plugin
| _ ->
assert false
in
......
(* The name of our [ppx_deriving] plugin. *)
let plugin =
"visitors"
......@@ -3,18 +3,12 @@ open List
let sprintf = Printf.sprintf
open Parsetree
open Ppx_deriving
open VisitorsPlugin
open VisitorsAnalysis
open VisitorsGeneration
(* -------------------------------------------------------------------------- *)
(* The name of our [ppx_deriving] plugin. *)
let plugin =
"visitors"
(* -------------------------------------------------------------------------- *)
(* We can generate classes that adhere to several distinct schemes, listed
below. These schemes differ only in the re-building code that is executed
after the recursive calls. In [iter], this code does nothing. In [map], it
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment