|
|
|
@ -6,6 +6,7 @@
|
|
|
|
|
(* Leonard Gerard, Parkas, ENS *)
|
|
|
|
|
(* Adrien Guatto, Parkas, ENS *)
|
|
|
|
|
(* Cedric Pasteur, Parkas, ENS *)
|
|
|
|
|
(* Marc Pouzet, Parkas, ENS *)
|
|
|
|
|
(* *)
|
|
|
|
|
(* Copyright 2012 ENS, INRIA, UJF *)
|
|
|
|
|
(* *)
|
|
|
|
@ -359,6 +360,11 @@ let translate_node
|
|
|
|
|
proc_body = body@body_c@body_sink;
|
|
|
|
|
proc_objectives = [obj] } in
|
|
|
|
|
|
|
|
|
|
let ctrlr_call =
|
|
|
|
|
begin
|
|
|
|
|
match controllables with
|
|
|
|
|
[] -> [] (* no controllable => no controller call *)
|
|
|
|
|
| _ :: _ ->
|
|
|
|
|
let ctrlr_pat = Minils.Etuplepat(List.map (fun { Minils.v_ident = v } ->
|
|
|
|
|
Minils.Evarpat(v))
|
|
|
|
|
mls_ctrl) in
|
|
|
|
@ -412,12 +418,14 @@ let translate_node
|
|
|
|
|
ctrlr_inputs ctrlr_outputs false false [] in
|
|
|
|
|
(* Add controller into modules *)
|
|
|
|
|
Modules.add_value ctrlr_fun_name ctrlr_signature;
|
|
|
|
|
[ctrlr_call]
|
|
|
|
|
end in
|
|
|
|
|
|
|
|
|
|
let node =
|
|
|
|
|
{ node with
|
|
|
|
|
Minils.n_contract = None;
|
|
|
|
|
Minils.n_local = node.Minils.n_local @ locals_c;
|
|
|
|
|
Minils.n_equs = ctrlr_call :: (node.Minils.n_equs @ eqs_c);
|
|
|
|
|
Minils.n_equs = ctrlr_call @ (node.Minils.n_equs @ eqs_c);
|
|
|
|
|
} in
|
|
|
|
|
node, p
|
|
|
|
|
|
|
|
|
|