diff options
author | Eric Botcazou <ebotcazou@adacore.com> | 2022-06-02 00:45:14 +0200 |
---|---|---|
committer | Pierre-Marie de Rodat <derodat@adacore.com> | 2022-07-04 07:46:00 +0000 |
commit | 1f03b43fc7552fe105d33612b3b89b4f0b222798 (patch) | |
tree | f57e2570922b954aae109ca384b43db44a06eba4 /gcc/gimple-loop-jam.cc | |
parent | 4dab9bed7bd173e55fa44b9d8f4a01dfd8566553 (diff) | |
download | gcc-1f03b43fc7552fe105d33612b3b89b4f0b222798.zip gcc-1f03b43fc7552fe105d33612b3b89b4f0b222798.tar.gz gcc-1f03b43fc7552fe105d33612b3b89b4f0b222798.tar.bz2 |
[Ada] Fix dispatching call to primitive function with controlling tagged result
When a dispatching call is made to a primitive function with a controlling
tagged result, the call is dispatching on result and thus must return the
class-wide type of the tagged type to accommodate all possible results.
This was ensured by Expand_Dispatching_Call only in the common case where
the result type is the type of the controlling argument, which does not
cover the case of a primitive function inherited from an ancestor type.
gcc/ada/
* exp_disp.adb (Expand_Dispatching_Call): Fix detection of calls
that are dispatching on tagged result.
Diffstat (limited to 'gcc/gimple-loop-jam.cc')
0 files changed, 0 insertions, 0 deletions