aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/sem_ch4.adb
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2020-03-09 10:14:53 +0100
committerPierre-Marie de Rodat <derodat@adacore.com>2020-06-10 09:35:01 -0400
commite156631a27d599f118ef2d384c6974172cd0c74d (patch)
treece2433134833e9d3d5c284f88fa453723390dfd3 /gcc/ada/sem_ch4.adb
parent2378f3eb81a5a7d4a31cd36ea99d9202eb21f0ef (diff)
downloadgcc-e156631a27d599f118ef2d384c6974172cd0c74d.zip
gcc-e156631a27d599f118ef2d384c6974172cd0c74d.tar.gz
gcc-e156631a27d599f118ef2d384c6974172cd0c74d.tar.bz2
[Ada] Remove obsolete code in Resolve_Call
2020-06-10 Eric Botcazou <ebotcazou@adacore.com> gcc/ada/ * sem_ch4.adb (Analyze_Call): Use idiomatic condition. * sem_res.adb (Resolve_Call): Remove obsolete code.
Diffstat (limited to 'gcc/ada/sem_ch4.adb')
-rw-r--r--gcc/ada/sem_ch4.adb3
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/ada/sem_ch4.adb b/gcc/ada/sem_ch4.adb
index 4ff08a5..3d3e2c7 100644
--- a/gcc/ada/sem_ch4.adb
+++ b/gcc/ada/sem_ch4.adb
@@ -1176,8 +1176,7 @@ package body Sem_Ch4 is
-- type is an array, F (X) cannot be interpreted as an indirect call
-- through the result of the call to F.
- elsif Is_Access_Type (Etype (Nam))
- and then Ekind (Designated_Type (Etype (Nam))) = E_Subprogram_Type
+ elsif Is_Access_Subprogram_Type (Base_Type (Etype (Nam)))
and then
(not Name_Denotes_Function
or else Nkind (N) = N_Procedure_Call_Statement