From 252a9169efef06b03061b58743be41e233a80ddb Mon Sep 17 00:00:00 2001 From: Vicente Bergas Date: Thu, 3 May 2018 19:28:49 +0200 Subject: Fix warning: use clause for package has no effect With gcc 8.1 the following message appears: warning: use clause for package "*" has no effect gnatmake: "*.adb" compilation error This patch fixes it. --- src/vhdl/translate/ortho_front.adb | 2 +- src/vhdl/translate/trans-chap12.adb | 4 ---- src/vhdl/translate/trans-chap7.adb | 10 ---------- src/vhdl/translate/trans-chap9.adb | 3 --- src/vhdl/translate/translation.adb | 1 - 5 files changed, 1 insertion(+), 19 deletions(-) (limited to 'src/vhdl/translate') diff --git a/src/vhdl/translate/ortho_front.adb b/src/vhdl/translate/ortho_front.adb index ac83f6142..236c94906 100644 --- a/src/vhdl/translate/ortho_front.adb +++ b/src/vhdl/translate/ortho_front.adb @@ -18,7 +18,7 @@ with Types; use Types; with Name_Table; with Iirs; use Iirs; -with Libraries; use Libraries; +with Libraries; with Iirs_Utils; use Iirs_Utils; with Std_Package; with Flags; diff --git a/src/vhdl/translate/trans-chap12.adb b/src/vhdl/translate/trans-chap12.adb index 920271fa0..9522b5cd2 100644 --- a/src/vhdl/translate/trans-chap12.adb +++ b/src/vhdl/translate/trans-chap12.adb @@ -424,10 +424,7 @@ package body Trans.Chap12 is -- Write to file FILELIST all the files that are needed to link the design. procedure Gen_Stubs is - use Interfaces.C_Streams; - use System; use Configuration; - use Name_Table; -- Add all dependences of UNIT. -- UNIT is not used, but added during link. @@ -595,7 +592,6 @@ package body Trans.Chap12 is Filelist : String; Whole : Boolean) is - use Name_Table; use Configuration; Unit : Iir_Design_Unit; diff --git a/src/vhdl/translate/trans-chap7.adb b/src/vhdl/translate/trans-chap7.adb index 1373ffdcd..5b70c71e7 100644 --- a/src/vhdl/translate/trans-chap7.adb +++ b/src/vhdl/translate/trans-chap7.adb @@ -168,8 +168,6 @@ package body Trans.Chap7 is Str : Iir; El_Type : Iir) is - use Name_Table; - Literal_List : constant Iir_Flist := Get_Enumeration_Literal_List (Get_Base_Type (El_Type)); Len : constant Nat32 := Get_String_Length (Str); @@ -272,8 +270,6 @@ package body Trans.Chap7 is function Translate_Static_String_Literal8 (Str : Iir) return O_Cnode is - use Name_Table; - Lit_Type : constant Iir := Get_Type (Str); Element_Type : constant Iir := Get_Element_Subtype (Lit_Type); Arr_Type : O_Tnode; @@ -297,8 +293,6 @@ package body Trans.Chap7 is function Create_String_Literal_Var_Inner (Str : Iir; Element_Type : Iir; Str_Type : O_Tnode) return Var_Type is - use Name_Table; - Val_Aggr : O_Array_Aggr_List; Res : O_Cnode; begin @@ -319,8 +313,6 @@ package body Trans.Chap7 is -- Create a variable (constant) for string or bit string literal STR. function Create_String_Literal_Var (Str : Iir) return Var_Type is - use Name_Table; - Str_Type : constant Iir := Get_Type (Str); Arr_Type : O_Tnode; begin @@ -339,8 +331,6 @@ package body Trans.Chap7 is -- because it is not so in VHDL! function Translate_Non_Static_String_Literal (Str : Iir) return O_Enode is - use Name_Table; - Len : constant Nat32 := Get_String_Length (Str); Lit_Type : constant Iir := Get_Type (Str); Type_Info : constant Type_Info_Acc := Get_Info (Lit_Type); diff --git a/src/vhdl/translate/trans-chap9.adb b/src/vhdl/translate/trans-chap9.adb index 35585d315..b1001a4ed 100644 --- a/src/vhdl/translate/trans-chap9.adb +++ b/src/vhdl/translate/trans-chap9.adb @@ -326,9 +326,6 @@ package body Trans.Chap9 is procedure Translate_Psl_Directive_Declarations (Stmt : Iir) is - use PSL.Nodes; - use PSL.NFAs; - Mark : Id_Mark_Type; Info : Ortho_Info_Acc; begin diff --git a/src/vhdl/translate/translation.adb b/src/vhdl/translate/translation.adb index 6baaaa995..69b63abee 100644 --- a/src/vhdl/translate/translation.adb +++ b/src/vhdl/translate/translation.adb @@ -105,7 +105,6 @@ package body Translation is function Translate_Foreign_Id (Decl : Iir) return Foreign_Info_Type is - use Name_Table; -- Look for 'FOREIGN. Attr : constant Iir_Attribute_Value := Sem_Specs.Find_Attribute_Value (Decl, Std_Names.Name_Foreign); -- cgit v1.2.3