diff options
author | Tristan Gingold | 2014-01-21 21:12:43 +0100 |
---|---|---|
committer | Tristan Gingold | 2014-01-21 21:12:43 +0100 |
commit | a5ab19a20dce3e46f73176b3b0534f71f2c44ef3 (patch) | |
tree | 6f8a63f0fb6e4b5e965e56cd3f4c705a505454ac | |
parent | 53bccc62d510f2a1df7500b3a5d916ec08d99c91 (diff) | |
download | ghdl-a5ab19a20dce3e46f73176b3b0534f71f2c44ef3.tar.gz ghdl-a5ab19a20dce3e46f73176b3b0534f71f2c44ef3.tar.bz2 ghdl-a5ab19a20dce3e46f73176b3b0534f71f2c44ef3.zip |
Avoid use before declaration.
-rw-r--r-- | translate/translation.adb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/translate/translation.adb b/translate/translation.adb index 7b9b6f3..ecc4a06 100644 --- a/translate/translation.adb +++ b/translate/translation.adb @@ -25263,6 +25263,7 @@ package body Translation is Prefix : Iir; Res : O_Dnode; Name_Cst : O_Dnode; + Str_Cst : O_Cnode; Constr : O_Assoc_List; Is_Instance : Boolean; begin @@ -25313,12 +25314,12 @@ package body Translation is Create_Temp_Stack2_Mark; Res := Create_Temp (Std_String_Node); + Str_Cst := Create_String_Len (Path_Str (1 .. Path_Len), + Create_Uniq_Identifier); New_Const_Decl (Name_Cst, Create_Uniq_Identifier, O_Storage_Private, Ghdl_Str_Len_Type_Node); Start_Const_Value (Name_Cst); - Finish_Const_Value (Name_Cst, - Create_String_Len (Path_Str (1 .. Path_Len), - Create_Uniq_Identifier)); + Finish_Const_Value (Name_Cst, Str_Cst); if Is_Instance then Start_Association (Constr, Ghdl_Get_Instance_Name); else |