Skip to content
Snippets Groups Projects
Commit 33d4cd49 authored by erwan's avatar erwan
Browse files

An ugly msg was printed in rpesence of -2c when no node was set.

parent 6710f70f
No related branches found
No related tags found
No related merge requests found
Pipeline #
OASISFormat: 0.4 OASISFormat: 0.4
Name: lustre-v6 Name: lustre-v6
Version: 1.730 Version: 1.731
Synopsis: The Lustre V6 Verimag compiler Synopsis: The Lustre V6 Verimag compiler
Description: This package contains: Description: This package contains:
- lus2lic: the (current) name of the compiler (and interpreter via -exec) - lus2lic: the (current) name of the compiler (and interpreter via -exec)
......
No preview for this file type
...@@ -2,6 +2,6 @@ ...@@ -2,6 +2,6 @@
let tool = "lus2lic" let tool = "lus2lic"
let branch = "master" let branch = "master"
let commit = "" let commit = ""
let sha_1 = "803db8564c42740d0cd58620c374a5189235c61d" let sha_1 = "6710f70f1ebdb1ad0bea5026e2901aa63fe799d5"
let str = (branch ^ "." ^ commit ^ " (" ^ sha_1 ^ ")") let str = (branch ^ "." ^ commit ^ " (" ^ sha_1 ^ ")")
let maintainer = "erwan.jahier@univ-grenoble-alpes.fr" let maintainer = "erwan.jahier@univ-grenoble-alpes.fr"
(* Time-stamp: <modified the 22/09/2017 (at 10:09) by Erwan Jahier> *) (* Time-stamp: <modified the 22/02/2018 (at 15:50) by Erwan Jahier> *)
open Lv6Verbose open Lv6Verbose
open AstV6 open AstV6
...@@ -89,7 +89,7 @@ let (gen_autotest_files : LicPrg.t -> Lv6Id.idref option -> Lv6MainArgs.t -> uni ...@@ -89,7 +89,7 @@ let (gen_autotest_files : LicPrg.t -> Lv6Id.idref option -> Lv6MainArgs.t -> uni
let main_node = Lv6Id.to_idref name in let main_node = Lv6Id.to_idref name in
let nk = (Lic.node_key_of_idref main_node) in let nk = (Lic.node_key_of_idref main_node) in
if LicPrg.node_exists lic_prg nk then ( if LicPrg.node_exists lic_prg nk then (
output_string stdout ("WARNING: No main node is specified. I'll try with " output_string stdout ("WARNING: No main node is specified: will use "
^ name ^"\n"); ^ name ^"\n");
flush stdout; flush stdout;
let msk, zesoc = Lic2soc.f lic_prg nk in let msk, zesoc = Lic2soc.f lic_prg nk in
...@@ -278,7 +278,7 @@ let main () = ( ...@@ -278,7 +278,7 @@ let main () = (
let name = find_a_node opt in let name = find_a_node opt in
let nk = (Lic.node_key_of_idref (Lv6Id.to_idref name)) in let nk = (Lic.node_key_of_idref (Lv6Id.to_idref name)) in
if LicPrg.node_exists lic_prg nk then ( if LicPrg.node_exists lic_prg nk then (
print_string ("WARNING: No main node is specified. I'll try with "^name^"\n"); print_string ("WARNING: No main node is specified: will use "^name^"\n");
flush stdout; flush stdout;
profile_info "Start compiling to soc...\n"; profile_info "Start compiling to soc...\n";
let msk,zesoc = Lic2soc.f lic_prg nk in let msk,zesoc = Lic2soc.f lic_prg nk in
...@@ -352,7 +352,7 @@ let main () = ( ...@@ -352,7 +352,7 @@ let main () = (
(* exit 1 *) (* exit 1 *)
(* ) *) (* ) *)
close_out opt.oc if opt.outfile <> "" then close_out opt.oc
);; );;
main(); main();
(* Time-stamp: <modified the 10/07/2017 (at 13:12) by Erwan Jahier> *) (* Time-stamp: <modified the 22/02/2018 (at 15:48) by Erwan Jahier> *)
(* let put (os: out_channel) (fmt:('a, unit, string, unit) format4) : 'a = *) (* let put (os: out_channel) (fmt:('a, unit, string, unit) format4) : 'a = *)
...@@ -971,7 +971,10 @@ typedef float _float; ...@@ -971,7 +971,10 @@ typedef float _float;
Printf.printf "%s has been generated.\n" hfile; Printf.printf "%s has been generated.\n" hfile;
Printf.printf "%s has been generated.\n" cfile; Printf.printf "%s has been generated.\n" cfile;
flush stdout; flush stdout;
let node = args.Lv6MainArgs.main_node in let node =
if args.Lv6MainArgs.main_node <> "" then args.Lv6MainArgs.main_node else
Filename.basename (Filename.chop_extension (List.hd args.Lv6MainArgs.infiles))
in
let execfile = if args.Lv6MainArgs.outfile = "" then (node^".exec") let execfile = if args.Lv6MainArgs.outfile = "" then (node^".exec")
else args.Lv6MainArgs.outfile else args.Lv6MainArgs.outfile
in in
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment