diff options
author | squirek <squirek@adacore.com> | 2024-10-21 18:21:13 +0000 |
---|---|---|
committer | Marc Poulhiès <dkm@gcc.gnu.org> | 2024-11-12 14:00:47 +0100 |
commit | 492f9cdf0046ba6d2452f8363d15b4449229b64c (patch) | |
tree | bd2e7cc8ec21f1bab18675901c4f3173f6d488fa /gcc | |
parent | b861785242450c8711aae6394751a75eadc4a0a9 (diff) | |
download | gcc-492f9cdf0046ba6d2452f8363d15b4449229b64c.zip gcc-492f9cdf0046ba6d2452f8363d15b4449229b64c.tar.gz gcc-492f9cdf0046ba6d2452f8363d15b4449229b64c.tar.bz2 |
ada: The Library_Unit field was used for all sorts of different purposes, which led to confusing code.
This patch further refines the previous work to fix several cases.
gcc/ada/ChangeLog:
* inline.adb (In_Main_Unit_Or_Subunit): Use Other_Comp_Unit instead of
Spec_Or_Body_Lib_Unit.
(Must_Inline): Use Other_Comp_Unit instead of Spec_Or_Body_Lib_Unit.
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ada/inline.adb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/ada/inline.adb b/gcc/ada/inline.adb index 9fa5642..a133ec7 100644 --- a/gcc/ada/inline.adb +++ b/gcc/ada/inline.adb @@ -498,7 +498,7 @@ package body Inline is -- package of the subprogram to find more calls to be inlined. if Comp = Cunit (Main_Unit) - or else Comp = Spec_Or_Body_Lib_Unit (Cunit (Main_Unit)) + or else Comp = Other_Comp_Unit (Cunit (Main_Unit)) then Add_Call (E); return Inline_Package; @@ -4716,7 +4716,7 @@ package body Inline is end loop; return Comp = Cunit (Main_Unit) - or else Comp = Spec_Or_Body_Lib_Unit (Cunit (Main_Unit)); + or else Comp = Other_Comp_Unit (Cunit (Main_Unit)); end In_Main_Unit_Or_Subunit; ---------------- |