aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/sem_ch13.adb
diff options
context:
space:
mode:
authorHristian Kirtchev <kirtchev@adacore.com>2015-05-26 09:20:53 +0000
committerArnaud Charlet <charlet@gcc.gnu.org>2015-05-26 11:20:53 +0200
commitb9eb3aa8a2f9c09ade591ed1a1edc12f0e73ed73 (patch)
treeb85c114cf0fec62a3131a2f88f521949d4895149 /gcc/ada/sem_ch13.adb
parenta12e42fc3dc64fb4183ee30e32906d3111552a17 (diff)
downloadgcc-b9eb3aa8a2f9c09ade591ed1a1edc12f0e73ed73.zip
gcc-b9eb3aa8a2f9c09ade591ed1a1edc12f0e73ed73.tar.gz
gcc-b9eb3aa8a2f9c09ade591ed1a1edc12f0e73ed73.tar.bz2
exp_ch6.adb (Process_Contract_Cases_For): Update the call to Expand_Pragma_Contract_Cases.
2015-05-26 Hristian Kirtchev <kirtchev@adacore.com> * exp_ch6.adb (Process_Contract_Cases_For): Update the call to Expand_Pragma_Contract_Cases. * exp_prag.ads, exp_prag.adb (Expand_Contract_Cases): Rename to Expand_Pragma_Contract_Cases. * sem_ch13.adb (Add_Invariants): Use the original aspect name when creating the arguments of pragma Check. This ensures that 'Class is properly recognized and handled. From-SVN: r223671
Diffstat (limited to 'gcc/ada/sem_ch13.adb')
-rw-r--r--gcc/ada/sem_ch13.adb9
1 files changed, 3 insertions, 6 deletions
diff --git a/gcc/ada/sem_ch13.adb b/gcc/ada/sem_ch13.adb
index 29153d7..f7dadef 100644
--- a/gcc/ada/sem_ch13.adb
+++ b/gcc/ada/sem_ch13.adb
@@ -8045,13 +8045,10 @@ package body Sem_Ch13 is
end;
end if;
- -- Get name to be used for Check pragma
+ -- Get name to be used for Check pragma. Using the original
+ -- name ensures that 'Class case is properly handled.
- if not From_Aspect_Specification (Ritem) then
- Nam := Name_Invariant;
- else
- Nam := Chars (Identifier (Corresponding_Aspect (Ritem)));
- end if;
+ Nam := Original_Aspect_Pragma_Name (Ritem);
-- Build first two arguments for Check pragma