Release coccinelle-0.2.4rc6
[bpt/coccinelle.git] / ocaml / coccilib.ml
1 (* Function table management *)
2
3 type pos = { current_element : string;
4 file :string ;
5 line : int;
6 col : int;
7 line_end : int;
8 col_end : int; }
9
10 type param_type =
11 Pos of pos list
12 | Str of string
13 | Type of Ast_c.fullType
14 | Init of Ast_c.initialiser
15 | Int of int
16 | Param of Ast_c.parameterType
17 | ParamList of Ast_c.parameterType Ast_c.wrap2 list
18 | Expr of Ast_c.expression
19 | ExprList of Ast_c.argument Ast_c.wrap2 list
20 | Decl of Ast_c.declaration
21 | Field of Ast_c.field
22 | Stmt of Ast_c.statement
23
24 let fcts : (string, param_type list -> string ref list -> unit) Hashtbl.t =
25 Hashtbl.create 11 (* Use prime number *)
26
27 (* ---------------------------------------------------------------------- *)
28 (* Match management *)
29
30 let inc_match = ref true
31 let include_match x = inc_match := x
32 let dir () = !Flag.dir