sem_util.adb (Subprogram_Name): Append suffix for overloaded subprograms.
2017-11-08 Arnaud Charlet <charlet@adacore.com> * sem_util.adb (Subprogram_Name): Append suffix for overloaded subprograms. From-SVN: r254529
This commit is contained in:
parent
e5148da096
commit
879e92d057
@ -1,3 +1,8 @@
|
||||
2017-11-08 Arnaud Charlet <charlet@adacore.com>
|
||||
|
||||
* sem_util.adb (Subprogram_Name): Append suffix for overloaded
|
||||
subprograms.
|
||||
|
||||
2017-11-08 Yannick Moy <moy@adacore.com>
|
||||
|
||||
* sem_ch8.adb (Use_One_Type, Update_Use_Clause_Chain): Do not report
|
||||
|
@ -23357,6 +23357,28 @@ package body Sem_Util is
|
||||
|
||||
Append_Entity_Name (Buf, Ent);
|
||||
|
||||
-- Append homonym number if needed
|
||||
|
||||
if Nkind (N) in N_Entity and then Has_Homonym (N) then
|
||||
declare
|
||||
H : Entity_Id := Homonym (N);
|
||||
Nr : Nat := 1;
|
||||
begin
|
||||
while Present (H) loop
|
||||
if Scope (H) = Scope (N) then
|
||||
Nr := Nr + 1;
|
||||
end if;
|
||||
|
||||
H := Homonym (H);
|
||||
end loop;
|
||||
|
||||
if Nr > 1 then
|
||||
Append (Buf, '#');
|
||||
Append (Buf, Nr);
|
||||
end if;
|
||||
end;
|
||||
end if;
|
||||
|
||||
-- Append source location of Ent to Buf so that the string will
|
||||
-- look like "subp:file:line:col".
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user