From 51be8c1991ae4fb9678dd1cfbb62a6ae568737aa Mon Sep 17 00:00:00 2001 From: Tristan Gingold Date: Wed, 19 Dec 2018 06:37:51 +0100 Subject: Sem: tolerates more parse errors. --- src/ghdldrv/ghdlcomp.adb | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/ghdldrv/ghdlcomp.adb') diff --git a/src/ghdldrv/ghdlcomp.adb b/src/ghdldrv/ghdlcomp.adb index e04369714..6be97c6ca 100644 --- a/src/ghdldrv/ghdlcomp.adb +++ b/src/ghdldrv/ghdlcomp.adb @@ -400,6 +400,9 @@ package body Ghdlcomp is Hooks.Compile_Init.all (True); + -- Analysis won't chock on incorrect parse tree. + Flags.Flag_Force_Analysis := Cmd.Flag_Force_Analysis; + -- Parse all files. for I in Args'Range loop Id := Name_Table.Get_Identifier (Args (I).all); @@ -428,7 +431,9 @@ package body Ghdlcomp is Next_Unit := Get_Chain (Unit); - if Errorout.Nbr_Errors = 0 then + if Errorout.Nbr_Errors = 0 + or else Cmd.Flag_Force_Analysis + then Set_Chain (Unit, Null_Iir); Libraries.Add_Design_Unit_Into_Library (Unit); New_Design_File := Get_Design_File (Unit); -- cgit v1.2.3