Project

General

Profile

« Previous | Next » 

Revision 5bbf7413

Added by Arnaud Dieumegard over 5 years ago

definition of the mini-vhdl types + pp + transformation from vhdl structure

View differences:

src/tools/importer/main_lustre_importer.ml
18 18
open Vhdl_ast_utils
19 19
open Vhdl_ast_map
20 20
open Vhdl_ast
21
open Mini_vhdl_ast
22
open Mini_vhdl_ast_pp
21 23
open Vhdl_ast_pp
22 24
open Vhdl_ast_yojson
23 25
open Printf
......
38 40
      (* Format.printf "Parsed VHDL: \n%s\n" (pretty_to_string (vhdl_file_t_to_yojson x)); *)
39 41
      (* Fold Op vhdl_expr_t values *)
40 42
      let folded = replace_op_expr#vhdl_file_t x in
41
      (* Translate vhdl_file_t value as lustre value *)
42
      let program = to_lustre#vhdl_file_t folded in
43
      Format.printf "%s\n" (show_vhdl_file_t program);
43
      (* Pretty-print vhdl *)
44
      Format.printf "============ Parsed VHDL ============\n%s\n" (show_vhdl_file_t folded);
45

  
46
      (* Translate vhdl_file_t value as mini_vhdl value *)
47
      let mini_vhdl = to_mini_vhdl#vhdl_design_file_t folded.design_file in
48
      Format.printf "============ Mini-VHDL ============\n%s\n" (show_mini_vhdl_design_file_t mini_vhdl);
44 49
      (* Pretty print lustre value *)
45 50
 (*     Printers.pp_prog std_formatter program; *)
46 51
      

Also available in: Unified diff