aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEd Schonberg <schonberg@adacore.com>2018-06-11 09:17:40 +0000
committerPierre-Marie de Rodat <pmderodat@gcc.gnu.org>2018-06-11 09:17:40 +0000
commitd6cb71164c56dd1b1f53acbb08f9fd5debc533df (patch)
treeca711a571af21c5022b04536a9d871f50269fb87
parenta8c316b2a138983d5d0e7204d142f4363ddb79dd (diff)
downloadgcc-d6cb71164c56dd1b1f53acbb08f9fd5debc533df.zip
gcc-d6cb71164c56dd1b1f53acbb08f9fd5debc533df.tar.gz
gcc-d6cb71164c56dd1b1f53acbb08f9fd5debc533df.tar.bz2
[Ada] Unnesting: fix handling of generic associations
2018-06-11 Ed Schonberg <schonberg@adacore.com> gcc/ada/ * exp_unst.adb (Visit_Node): Skip generic associations. From-SVN: r261408
-rw-r--r--gcc/ada/ChangeLog4
-rw-r--r--gcc/ada/exp_unst.adb7
2 files changed, 11 insertions, 0 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index 791942d..d0722f7 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -1,3 +1,7 @@
+2018-06-11 Ed Schonberg <schonberg@adacore.com>
+
+ * exp_unst.adb (Visit_Node): Skip generic associations.
+
2018-06-11 Arnaud Charlet <charlet@adacore.com>
* libgnat/memtrack.adb (fwrite): Remove second definition.
diff --git a/gcc/ada/exp_unst.adb b/gcc/ada/exp_unst.adb
index 9ad43f4..1cdb2a5 100644
--- a/gcc/ada/exp_unst.adb
+++ b/gcc/ada/exp_unst.adb
@@ -825,6 +825,13 @@ package body Exp_Unst is
return Skip;
end if;
+ -- Generic associations are not analyzed: the actuals are
+ -- transferred to renaming qnd subtype declarations that
+ -- are the ones that must be examined.
+
+ when N_Generic_Association =>
+ return Skip;
+
-- Indexed references can be uplevel if the type isn't static
-- and if the lower bound (or an inner bound for a multi-
-- dimensional array) is uplevel.