2 * Copyright 2005-2010, Ecole des Mines de Nantes, University of Copenhagen
3 * Yoann Padioleau, Julia Lawall, Rene Rydhof Hansen, Henrik Stuart, Gilles Muller, Nicolas Palix
4 * This file is part of Coccinelle.
6 * Coccinelle is free software: you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation, according to version 2 of the License.
10 * Coccinelle is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with Coccinelle. If not, see <http://www.gnu.org/licenses/>.
18 * The authors reserve the right to distribute this or future versions of
19 * Coccinelle under other licenses.
24 * Copyright 2005-2010, Ecole des Mines de Nantes, University of Copenhagen
25 * Yoann Padioleau, Julia Lawall, Rene Rydhof Hansen, Henrik Stuart, Gilles Muller, Nicolas Palix
26 * This file is part of Coccinelle.
28 * Coccinelle is free software: you can redistribute it and/or modify
29 * it under the terms of the GNU General Public License as published by
30 * the Free Software Foundation, according to version 2 of the License.
32 * Coccinelle is distributed in the hope that it will be useful,
33 * but WITHOUT ANY WARRANTY; without even the implied warranty of
34 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
35 * GNU General Public License for more details.
37 * You should have received a copy of the GNU General Public License
38 * along with Coccinelle. If not, see <http://www.gnu.org/licenses/>.
40 * The authors reserve the right to distribute this or future versions of
41 * Coccinelle under other licenses.
47 type ('pred
, 'mvar
) wrapped_ctl
=
48 ('pred
* 'mvar
Ast_ctl.modif
, 'mvar
, info
) Ast_ctl.generic_ctl
50 type ('a
, 'b
) wrapped_binding
=
52 | PredVal
of 'b
Ast_ctl.modif
54 type ('pred
,'state
,'mvar
,'
value) labelfunc
=
56 ('state
* ('pred
* ('mvar
, '
value) Ast_ctl.generic_substitution
)) list
58 module CTL_ENGINE_BIS
:
59 functor (SUB
: Ctl_engine.SUBST
) ->
60 functor (G
: Ctl_engine.GRAPH
) ->
61 functor(P
: Ctl_engine.PREDICATE
) ->
68 type value = (SUB.value, predicate
) wrapped_binding
72 type t
= P.t
* SUB.mvar
Ast_ctl.modif
74 module WRAPPER_ENGINE
:
77 (WRAPPER_ENV.mvar
, WRAPPER_ENV.value) Ast_ctl.generic_subst list
78 type ('a
, 'b
) witness
=
79 (G.node
, substitution
,
80 ('a
, WRAPPER_ENV.mvar
, 'b
) Ast_ctl.generic_ctl list
)
81 Ast_ctl.generic_witnesstree
82 type ('a
, 'b
) triples
=
83 (G.node
* substitution
* ('a
, 'b
) witness list
) list
89 (predicate
, G.node
, WRAPPER_ENV.mvar
, SUB.value) labelfunc
*
91 ((WRAPPER_PRED.t
, WRAPPER_ENV.mvar
, int) Ast_ctl.generic_ctl
*
92 (WRAPPER_PRED.t list list
)) ->
93 (WRAPPER_PRED.t
, 'a
) WRAPPER_ENGINE.triples
97 (predicate
,G.node
,SUB.mvar
,SUB.value) labelfunc
*
99 ((predicate
,SUB.mvar
) wrapped_ctl
*
100 (WRAPPER_PRED.t list list
)) ->
101 (WRAPPER_ENV.mvar list
* (SUB.mvar
* SUB.value) list
) ->
102 ((WRAPPER_PRED.t
, 'a
) WRAPPER_ENGINE.triples
*
103 ((G.node
* (SUB.mvar
* SUB.value) list
* predicate
)
106 (WRAPPER_ENV.mvar
* SUB.value) list list
))
108 val print_bench
: unit -> unit