aboutsummaryrefslogtreecommitdiffstats
path: root/src/ghdldrv
diff options
context:
space:
mode:
authorTristan Gingold <tgingold@free.fr>2014-12-22 11:58:05 +0100
committerTristan Gingold <tgingold@free.fr>2014-12-22 11:58:05 +0100
commit6aa5c00499ff83aa5926017c87339b5493cea4db (patch)
tree1289ede59c454637e12a9f1a5e19413600ad02d8 /src/ghdldrv
parent846f7e02d664702bedc5ed086c7753bd93e3ba97 (diff)
downloadghdl-6aa5c00499ff83aa5926017c87339b5493cea4db.tar.gz
ghdl-6aa5c00499ff83aa5926017c87339b5493cea4db.tar.bz2
ghdl-6aa5c00499ff83aa5926017c87339b5493cea4db.zip
Add comments.
Diffstat (limited to 'src/ghdldrv')
-rw-r--r--src/ghdldrv/ghdldrv.adb2
-rw-r--r--src/ghdldrv/ghdllocal.adb9
2 files changed, 8 insertions, 3 deletions
diff --git a/src/ghdldrv/ghdldrv.adb b/src/ghdldrv/ghdldrv.adb
index 6ffeef8a3..7e418d6b2 100644
--- a/src/ghdldrv/ghdldrv.adb
+++ b/src/ghdldrv/ghdldrv.adb
@@ -1470,6 +1470,8 @@ package body Ghdldrv is
Unit := Get_First_Design_Unit (File);
while Unit /= Null_Iir loop
Lib_Unit := Get_Library_Unit (Unit);
+ -- Check if the unit is outdated (except for default
+ -- configurations).
if not (Get_Kind (Lib_Unit) = Iir_Kind_Configuration_Declaration
and then Get_Identifier (Lib_Unit) = Null_Identifier)
then
diff --git a/src/ghdldrv/ghdllocal.adb b/src/ghdldrv/ghdllocal.adb
index be4587d63..ede9526f0 100644
--- a/src/ghdldrv/ghdllocal.adb
+++ b/src/ghdldrv/ghdllocal.adb
@@ -1207,6 +1207,7 @@ package body Ghdllocal is
Work_Library := Old_Work;
end Load_All_Libraries_And_Files;
+ -- Check the Elab_Flag is not set on design units of LIB.
procedure Check_No_Elab_Flag (Lib : Iir_Library_Declaration)
is
File : Iir_Design_File;
@@ -1271,6 +1272,7 @@ package body Ghdllocal is
end if;
if True then
+ -- Load the world.
Load_All_Libraries_And_Files;
else
-- Re-parse modified files in order configure could find all design
@@ -1313,11 +1315,11 @@ package body Ghdllocal is
Top := Configure (Primary_Id, Secondary_Id);
if Top = Null_Iir then
- --Error ("cannot find primary unit " & Prim.all);
+ -- Error during configuration (primary unit not found).
raise Option_Error;
end if;
- -- Add unused design units.
+ -- Add unused design units (and their dependencies).
declare
N : Natural;
begin
@@ -1339,7 +1341,8 @@ package body Ghdllocal is
end loop;
end;
- -- Clear elab flag on design files.
+ -- Clear elab flag on design files (as it is used by below by
+ -- Build_Dependence_List).
for I in reverse Design_Units.First .. Design_Units.Last loop
Unit := Design_Units.Table (I);
File := Get_Design_File (Unit);