diff options
author | Arnaud Charlet <charlet@gcc.gnu.org> | 2017-04-25 14:00:46 +0200 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2017-04-25 14:00:46 +0200 |
commit | 321c24f75dde674402481f1df0025c8169aa9cdd (patch) | |
tree | 60c389a4af1d5a6dcd6d295987bda6a9f9a76fcc /gcc/ada/sem_util.ads | |
parent | 6948bc18f0a5bd5cfca40f6d18131b0673f05541 (diff) | |
download | gcc-321c24f75dde674402481f1df0025c8169aa9cdd.zip gcc-321c24f75dde674402481f1df0025c8169aa9cdd.tar.gz gcc-321c24f75dde674402481f1df0025c8169aa9cdd.tar.bz2 |
[multiple changes]
2017-04-25 Ed Schonberg <schonberg@adacore.com>
* sem_ch3.adb (Add_Internal_Interface_Entities): Move
Has_Non_Trivial_Precondition to sem_util. for use elsewhere.
Improve error message on operations that inherit non-conforming
classwide preconditions from ancestor and progenitor.
* sem_util.ads, sem_util.adb (Has_Non_Trivial_Precondition):
moved here from sem_ch3.
* sem_ch8.adb (Analyze_Subprogram_Renaming): Implement legality
check given in RM 6.1.1 (17) concerning renamings of overriding
operations that inherits class-wide preconditions from ancestor
or progenitor.
2017-04-25 Hristian Kirtchev <kirtchev@adacore.com>
* exp_ch7.adb (Build_Adjust_Or_Finalize_Statements): Code cleanup.
(Build_Adjust_Statements): Code cleanup.
(Build_Finalizer): Update the initialization of
Exceptions_OK.
(Build_Finalize_Statements): Code cleanup.
(Build_Initialize_Statements): Code cleanup.
(Make_Deep_Array_Body): Update the initialization of
Exceptions_OK.
(Make_Deep_Record_Body): Update the initialization of Exceptions_OK.
(Process_Object_Declaration): Generate a null exception handler only
when exceptions are allowed.
(Process_Transients_In_Scope): Update the initialization of
Exceptions_OK.
* exp_util.ads, exp_util.adb (Exceptions_In_Finalization_OK): New
routine.
* sem_ch11.adb (Analyze_Exception_Handlers): Do not check any
restrictions when the handler is internally generated and the
mode is warnings.
2017-04-25 Ed Schonberg <schonberg@adacore.com>
* sem_ch3.adb (Has_Non_Trivial_Precondition): New predicate to
enforce legality rule on classwide preconditions inherited from
both an ancestor and a progenitor (RM 6.1.1 (10-13).
* sem_disp.adb (Check_Dispatching_Context): A call to an abstract
subprogram need not be dispatching if it appears in a precondition
for an abstract or null subprogram.
2017-04-25 Gary Dismukes <dismukes@adacore.com>
* sem_ch10.adb: Minor typo fix.
From-SVN: r247192
Diffstat (limited to 'gcc/ada/sem_util.ads')
-rw-r--r-- | gcc/ada/sem_util.ads | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/ada/sem_util.ads b/gcc/ada/sem_util.ads index e3afc1b..0d5de62 100644 --- a/gcc/ada/sem_util.ads +++ b/gcc/ada/sem_util.ads @@ -1169,6 +1169,10 @@ package Sem_Util is -- null statement, possibly followed by an optional return. Used to -- optimize useless calls to assertion checks. + function Has_Non_Trivial_Precondition (P : Entity_Id) return Boolean; + -- True if subprogram has a class-wide precondition that is not + -- statically True. + function Has_Null_Exclusion (N : Node_Id) return Boolean; -- Determine whether node N has a null exclusion |