Commit 12761e48 authored by Jerome Hugues's avatar Jerome Hugues
Browse files

* (Map_C_Enumerator_Name): Add the option to fully qualify name with

parentn name
parent 96289202
......@@ -928,6 +928,7 @@ package body Ocarina.Backends.C_Common.Mapping is
function Map_C_Enumerator_Name
(E : Node_Id;
Custom_Parent : Node_Id := No_Node;
Fully_Qualify_Parent : Boolean := False;
Entity : Boolean := False;
Server : Boolean := False;
Port_Type : Boolean := False;
......@@ -939,10 +940,19 @@ package body Ocarina.Backends.C_Common.Mapping is
if Kind (E) = K_Port_Spec_Instance then
C_Name_1 := CTU.To_C_Name (Display_Name (Identifier (E)));
if Fully_Qualify_Parent then
(Parent_Component ((E)))));
(Identifier (Parent_Subcomponent (Parent_Component (E))))));
(Identifier (Parent_Subcomponent
(Parent_Component (E))))));
end if;
if Local_Port then
Add_Str_To_Name_Buffer ("_local_");
Get_Name_String_And_Append (C_Name_1);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment