diff options
author | Eric Botcazou <ebotcazou@adacore.com> | 2019-08-14 09:52:43 +0000 |
---|---|---|
committer | Pierre-Marie de Rodat <pmderodat@gcc.gnu.org> | 2019-08-14 09:52:43 +0000 |
commit | 0cc1d9ad98fdabe6c577de1a83c4e12821f0c333 (patch) | |
tree | ae7a92b43da506bbb8c9c33d7c52325a62e89e22 | |
parent | 022c9dfe1f92a51da29a70a95b7af2f0541b6ab0 (diff) | |
download | gcc-0cc1d9ad98fdabe6c577de1a83c4e12821f0c333.zip gcc-0cc1d9ad98fdabe6c577de1a83c4e12821f0c333.tar.gz gcc-0cc1d9ad98fdabe6c577de1a83c4e12821f0c333.tar.bz2 |
[Ada] Further cleanup in inlining machinery
No practical functional changes.
2019-08-14 Eric Botcazou <ebotcazou@adacore.com>
gcc/ada/
* inline.adb (Add_Pending_Instantiation): Use greater-or-equal
in the comparison against the maximum number of instantiations.
From-SVN: r274471
-rw-r--r-- | gcc/ada/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/ada/inline.adb | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 1c869e1..a8de811 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,8 @@ +2019-08-14 Eric Botcazou <ebotcazou@adacore.com> + + * inline.adb (Add_Pending_Instantiation): Use greater-or-equal + in the comparison against the maximum number of instantiations. + 2019-08-14 Ed Schonberg <schonberg@adacore.com> * sem_aux.adb (Next_Rep_Item): If a node in the rep chain diff --git a/gcc/ada/inline.adb b/gcc/ada/inline.adb index 5dbd9a1..15cec51 100644 --- a/gcc/ada/inline.adb +++ b/gcc/ada/inline.adb @@ -794,7 +794,7 @@ package body Inline is -- Here is a defense against a ludicrous number of instantiations -- caused by a circular set of instantiation attempts. - if Pending_Instantiations.Last > Maximum_Instantiations then + if Pending_Instantiations.Last >= Maximum_Instantiations then Error_Msg_Uint_1 := UI_From_Int (Maximum_Instantiations); Error_Msg_N ("too many instantiations, exceeds max of^", Inst); Error_Msg_N ("\limit can be changed using -gnateinn switch", Inst); |