Project

General

Profile

« Previous | Next » 

Revision 304640aa

Added by Arnaud Dieumegard over 3 years ago

update of mini-vhdl to lustre

View differences:

src/tools/importer/mini_vhdl_to_lustre.ml
23 23
    method virtual  mini_vhdl_design_file_t : 
24 24
      mini_vhdl_design_file_t -> program
25 25

  
26
    method mini_vhdl_declaration_t : mini_vhdl_declaration_t -> mini_vhdl_declaration_t=
27
      fun x -> x
28

  
29
    method mini_vhdl_process_t : mini_vhdl_process_t -> mini_vhdl_process_t=
30
      fun x -> x
31

  
26 32
    method mini_vhdl_component_instantiation_t :
27 33
      mini_vhdl_component_instantiation_t -> statement=
28 34
      fun { name; archi; entity; generic_map; port_map }  ->
......
41 47
      mini_vhdl_concurrent_stmt_t -> statement=
42 48
      fun x  ->
43 49
        match x with
44
        | SigAssign a ->
45
            let a = self#vhdl_conditional_signal_t a  in
46
            Eq {eq_lhs=["SigAssign"];
47
                eq_rhs={expr_tag=Utils.new_tag (); expr_desc=Expr_ident "toto";
48
                        expr_type={tdesc=Tconst "cst"; tid=0}; expr_clock={cdesc=Cvar;cscoped=false;cid=0};
49
                        expr_delay={ddesc=Dundef;did=0}; expr_annot=None; expr_loc=Location.dummy_loc};
50
                eq_loc=Location.dummy_loc}
51
        | Process a -> let a = self#vhdl_process_t a  in
50
        | Process a -> let a = self#mini_vhdl_process_t a  in
52 51
            Eq {eq_lhs=["Process"];
53 52
                eq_rhs={expr_tag=Utils.new_tag (); expr_desc=Expr_ident "toto";
54 53
                        expr_type={tdesc=Tconst "cst"; tid=0}; expr_clock={cdesc=Cvar;cscoped=false;cid=0};
......
64 63
        | ComponentInst a ->
65 64
            let a = self#mini_vhdl_component_instantiation_t a  in a
66 65

  
67
    method mini_vhdl_package_t : vhdl_package_t -> top_decl_desc=
66
    method mini_vhdl_package_t : mini_vhdl_package_t -> top_decl_desc=
68 67
      fun { name; shared_defs; shared_decls; shared_uses }  ->
69 68
        let name = self#vhdl_name_t name  in
70 69
        let shared_defs = self#list self#vhdl_definition_t shared_defs  in
71
        let shared_decls = self#list self#vhdl_declaration_t shared_decls  in
70
        let shared_decls = List.map self#mini_vhdl_declaration_t shared_decls  in
72 71
        let shared_uses = self#list self#vhdl_load_t shared_uses in
73 72
        let node_id = show_vhdl_name_t name in
74 73
        let node_type = Types.new_var () in
......
88 87
        let generics = self#list self#vhdl_port_t generics  in
89 88
        let ports = self#list self#vhdl_port_t ports  in
90 89
        let contexts = self#list self#vhdl_load_t contexts  in
91
        let declarations = self#list self#vhdl_declaration_t declarations  in
90
        let declarations = List.map self#mini_vhdl_declaration_t declarations  in
92 91
        let definitions = self#list self#vhdl_definition_t definitions  in
93 92
        let body = List.map self#mini_vhdl_concurrent_stmt_t body  in
94 93
        let node_id = String.concat "__" (List.map show_vhdl_name_t names) in

Also available in: Unified diff