aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/sem_ch4.adb
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2011-08-03 12:10:40 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2011-08-03 12:10:40 +0200
commit95eb8b69e6289ad1bc196915ba741f035817ce4b (patch)
tree26c7af0748202e6e8920fded388bf64f284d3c3c /gcc/ada/sem_ch4.adb
parent92e770277f735559fae532ddcf7307d50e209b2f (diff)
downloadgcc-95eb8b69e6289ad1bc196915ba741f035817ce4b.zip
gcc-95eb8b69e6289ad1bc196915ba741f035817ce4b.tar.gz
gcc-95eb8b69e6289ad1bc196915ba741f035817ce4b.tar.bz2
[multiple changes]
2011-08-03 Javier Miranda <miranda@adacore.com> * exp_util.adb, sem_aux.adb, exp_util.ads, sem_aux.ads: Move routine Is_VM_By_Copy_Actual from sem_aux to exp_util. 2011-08-03 Bob Duff <duff@adacore.com> * sem_ch8.adb (Is_Primitive_Operator_In_Use): Always check In_Use on the Base_Type. 2011-08-03 Joel Brobecker <brobecker@adacore.com brobecker> * g-sha256.ads, g-sha512.ads, g-sha1.ads, g-sha224.ads, g-sha384.ads, g-sehash.ads: Fix typo. Update header. 2011-08-03 Thomas Quinot <quinot@adacore.com> * exp_ch6.adb (Expand_Actuals): Remove Ada_2005 guard on build-in-place expansion. 2011-08-03 Gary Dismukes <dismukes@adacore.com> * sem_ch4.adb (Analyze_Overloaded_Selected_Component): Consider prefixes of private types along with records, since the selector may be a discriminant. * sem_res.adb (Resolve_Selected_Component): Consider prefixes of private types along with records, since the selector may be a discriminant. From-SVN: r177259
Diffstat (limited to 'gcc/ada/sem_ch4.adb')
-rw-r--r--gcc/ada/sem_ch4.adb5
1 files changed, 4 insertions, 1 deletions
diff --git a/gcc/ada/sem_ch4.adb b/gcc/ada/sem_ch4.adb
index 912e09b..664a080 100644
--- a/gcc/ada/sem_ch4.adb
+++ b/gcc/ada/sem_ch4.adb
@@ -3127,7 +3127,10 @@ package body Sem_Ch4 is
T := It.Typ;
end if;
- if Is_Record_Type (T) then
+ -- Locate the component. For a private prefix the selector can denote
+ -- a discriminant.
+
+ if Is_Record_Type (T) or else Is_Private_Type (T) then
-- If the prefix is a class-wide type, the visible components are
-- those of the base type.