diff options
author | Piotr Trojanek <trojanek@adacore.com> | 2023-04-05 23:55:30 +0200 |
---|---|---|
committer | Marc Poulhiès <poulhies@adacore.com> | 2023-05-29 10:23:21 +0200 |
commit | f82fb00286eb774776c5f0e1cfdfd4981764d8f6 (patch) | |
tree | 6b4636ebb282628dd953d8db78983e154093e79f /gcc/ada/sem_disp.adb | |
parent | 8eb9a6b4c4b68fb39f02608787e2bd9836544cad (diff) | |
download | gcc-f82fb00286eb774776c5f0e1cfdfd4981764d8f6.zip gcc-f82fb00286eb774776c5f0e1cfdfd4981764d8f6.tar.gz gcc-f82fb00286eb774776c5f0e1cfdfd4981764d8f6.tar.bz2 |
ada: Cleanup detection of type support subprogram entities
Avoid repeated calls to Get_TSS_Name. Code cleanup related to handling
of dispatching operations in GNATprove; semantics is unaffected.
gcc/ada/
* exp_aggr.adb (Convert_Aggr_In_Allocator): Replace Get_TSS_Name
with a high-level Is_TSS.
* sem_ch6.adb (Check_Conformance): Replace DECLARE block and
nested IF with a call to Get_TSS_Name and a membership test.
(Has_Reliable_Extra_Formals): Refactor repeated calls to
Get_TSS_Name.
* sem_disp.adb (Check_Dispatching_Operation): Replace repeated
calls to Get_TSS_Name with a membership test.
Diffstat (limited to 'gcc/ada/sem_disp.adb')
-rw-r--r-- | gcc/ada/sem_disp.adb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/ada/sem_disp.adb b/gcc/ada/sem_disp.adb index ab409d3..6c8212c 100644 --- a/gcc/ada/sem_disp.adb +++ b/gcc/ada/sem_disp.adb @@ -1414,9 +1414,9 @@ package body Sem_Disp is and then Is_Null_Interface_Primitive (Ultimate_Alias (Old_Subp))) - or else Get_TSS_Name (Subp) = TSS_Stream_Read - or else Get_TSS_Name (Subp) = TSS_Stream_Write - or else Get_TSS_Name (Subp) = TSS_Put_Image + or else Get_TSS_Name (Subp) in TSS_Stream_Read + | TSS_Stream_Write + | TSS_Put_Image or else (Is_Wrapper (Subp) |