Project

General

Profile

Revision 53206908 src/compiler_common.ml

View differences:

src/compiler_common.ml
14 14
open LustreSpec
15 15
open Corelang
16 16

  
17
let check_main () =
18
  if !Options.main_node = "" then
19
    begin
20
      eprintf "Code generation error: %a@." pp_error No_main_specified;
21
      raise (Error (Location.dummy_loc, No_main_specified))
22
    end
23

  
17 24
let create_dest_dir () =
18 25
  begin
19 26
    if not (Sys.file_exists !Options.dest_dir) then
......
88 95
      Location.pp_loc loc;
89 96
    raise exc
90 97

  
98
let force_stateful_decls decls =
99
  Log.report ~level:1 (fun fmt -> fprintf fmt ".. forcing stateful status@ ");
100
  try
101
    Stateless.force_prog decls
102
  with (Stateless.Error (loc, err)) as exc ->
103
    eprintf "Stateless status error: %a%a@."
104
      Stateless.pp_error err
105
      Location.pp_loc loc;
106
    raise exc
107

  
91 108
let type_decls env decls =  
92 109
  Log.report ~level:1 (fun fmt -> fprintf fmt ".. typing@ ");
93 110
  let new_env = 

Also available in: Unified diff