aboutsummaryrefslogtreecommitdiffstats
path: root/src/ghdldrv
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2016-09-18 15:00:11 +0200
committerTristan Gingold <tgingold@free.fr>2016-09-18 15:00:11 +0200
commit6284c9c6baf057a4421b1163328621c707349080 (patch)
tree5bbd750e0935cc1acaab73f4719bedc0878d47b2 /src/ghdldrv
parent295084718d1b9307d7adac59f6396b740807155a (diff)
downloadghdl-6284c9c6baf057a4421b1163328621c707349080.tar.gz
ghdl-6284c9c6baf057a4421b1163328621c707349080.tar.bz2
ghdl-6284c9c6baf057a4421b1163328621c707349080.zip
ghdl_local: minor rewrite.
Diffstat (limited to 'src/ghdldrv')
-rw-r--r--src/ghdldrv/ghdllocal.adb14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/ghdldrv/ghdllocal.adb b/src/ghdldrv/ghdllocal.adb
index 3a9ec6a04..ffb50bcbd 100644
--- a/src/ghdldrv/ghdllocal.adb
+++ b/src/ghdldrv/ghdllocal.adb
@@ -50,8 +50,8 @@ package body Ghdllocal is
(Unit : Iir_Design_Unit; Main : Boolean := False)
is
use Errorout;
+ Lib_Unit : constant Iir := Get_Library_Unit (Unit);
Config : Iir_Design_Unit;
- Lib : Iir;
begin
if (Main or Flags.Dump_All) and then Flags.Dump_Parse then
Disp_Tree.Disp_Tree (Unit);
@@ -59,7 +59,7 @@ package body Ghdllocal is
if Flags.Verbose then
Report_Msg (Msgid_Note, Semantic, +Unit,
- "analyze %n", (1 => +Get_Library_Unit (Unit)));
+ "analyze %n", (1 => +Lib_Unit));
end if;
Sem.Semantic (Unit);
@@ -87,7 +87,7 @@ package body Ghdllocal is
then
if Flags.Verbose then
Report_Msg (Msgid_Note, Semantic, No_Location,
- "canonicalize %n", (1 => +Get_Library_Unit (Unit)));
+ "canonicalize %n", (1 => +Lib_Unit));
end if;
Canon.Canonicalize (Unit);
@@ -98,10 +98,10 @@ package body Ghdllocal is
end if;
if Flags.Flag_Elaborate then
- Lib := Get_Library_Unit (Unit);
- if Get_Kind (Lib) = Iir_Kind_Architecture_Body then
- Config := Canon.Create_Default_Configuration_Declaration (Lib);
- Set_Default_Configuration_Declaration (Lib, Config);
+ if Get_Kind (Lib_Unit) = Iir_Kind_Architecture_Body then
+ Config :=
+ Canon.Create_Default_Configuration_Declaration (Lib_Unit);
+ Set_Default_Configuration_Declaration (Lib_Unit, Config);
end if;
end if;
end Finish_Compilation;