diff options
author | Bob Duff <duff@adacore.com> | 2020-03-14 14:32:31 -0400 |
---|---|---|
committer | Giuliano Belinassi <giuliano.belinassi@usp.br> | 2020-08-17 13:12:03 -0300 |
commit | ef71af1d4a2551c92a3453530c592c29a97f0838 (patch) | |
tree | d5ce713f8667d779a58e2f1b7b351846caada6e2 /gcc | |
parent | 26d3c8d2cf209c95382c22c91a94e1caf057b95c (diff) | |
download | gcc-ef71af1d4a2551c92a3453530c592c29a97f0838.zip gcc-ef71af1d4a2551c92a3453530c592c29a97f0838.tar.gz gcc-ef71af1d4a2551c92a3453530c592c29a97f0838.tar.bz2 |
[Ada] Fix unnesting crash with Predicate_Failure/no pred
2020-06-11 Bob Duff <duff@adacore.com>
gcc/ada/
* sem_ch13.adb (Analyze_Aspect_Specifications): Do not set the
Has_Predicates flag when the Predicate_Failure aspect is seen.
It is legal (but pointless) to use this aspect without a
predicate. If we set the flag, we generate a half-baked
Predicate procedure, and if that procedure is nested, it causes
unnesting to crash.
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ada/sem_ch13.adb | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/gcc/ada/sem_ch13.adb b/gcc/ada/sem_ch13.adb index cb33439..f73b55a 100644 --- a/gcc/ada/sem_ch13.adb +++ b/gcc/ada/sem_ch13.adb @@ -2540,8 +2540,6 @@ package body Sem_Ch13 is Expression => Relocate_Node (Expr))), Pragma_Name => Name_Predicate_Failure); - Set_Has_Predicates (E); - -- If the type is private, indicate that its completion -- has a freeze node, because that is the one that will -- be visible at freeze time. |