aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/contracts.adb
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@adacore.com>2020-07-09 05:36:18 -0400
committerPierre-Marie de Rodat <derodat@adacore.com>2020-10-19 05:53:39 -0400
commit44ecd94cc7daf60ed04a81107c8d52c23cfef84d (patch)
treef31c15254dbde216d8d5cb3318c52d6bbd165df9 /gcc/ada/contracts.adb
parentb0a16e6d4c91120dd9a2900da0831e83e65f2046 (diff)
downloadgcc-44ecd94cc7daf60ed04a81107c8d52c23cfef84d.zip
gcc-44ecd94cc7daf60ed04a81107c8d52c23cfef84d.tar.gz
gcc-44ecd94cc7daf60ed04a81107c8d52c23cfef84d.tar.bz2
[Ada] Wrong freezing for expression function with contracts in a generic
gcc/ada/ * contracts.adb (Process_Preconditions_For): Do not exclude instances. * sem_ch4.adb (Analyze_Quantified_Expression): Disable spurious warning on internally generated variables.
Diffstat (limited to 'gcc/ada/contracts.adb')
-rw-r--r--gcc/ada/contracts.adb3
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/ada/contracts.adb b/gcc/ada/contracts.adb
index 9d3e9e9..666a57f 100644
--- a/gcc/ada/contracts.adb
+++ b/gcc/ada/contracts.adb
@@ -2590,8 +2590,7 @@ package body Contracts is
and then Sloc (Body_Id) /= Sloc (Subp_Id)
and then In_Same_Source_Unit (Body_Id, Subp_Id)
and then List_Containing (Body_Decl) /=
- List_Containing (Subp_Decl)
- and then not In_Instance;
+ List_Containing (Subp_Decl);
if Present (Items) then
Prag := Pre_Post_Conditions (Items);