[Ada] Limited function violates No_Exception_Propagation
This patch suppresses the generation of raise statements in the context
of build-in-place and elaboration checks for primitives of tagged types
when exceptions cannot be used.
2018-11-14 Hristian Kirtchev <kirtchev@adacore.com>
gcc/ada/
* checks.adb (Install_Primitive_Elaboration_Check): Do not
create the check when exceptions cannot be used.
* exp_ch6.adb (Expand_N_Extended_Return_Statement): Do not raise
Program_Errror when exceptions cannot be used. Analyze the
generated code with all checks suppressed.
* exp_ch7.adb (Build_Finalizer): Remove the declaration of
Exceptions_OK.
(Make_Deep_Array_Body): Remove the declaration of Exceptions_OK.
(Make_Deep_Record_Body): Remove the declaration of
Exceptions_OK.
(Process_Transients_In_Scope): Remove the declaration of
Exceptions_OK.
* exp_util.adb (Exceptions_In_Finalization_OK): Renamed to
Exceptions_OK.
* exp_util.ads (Exceptions_In_Finalization_OK): Renamed to
Exceptions_OK.
gcc/testsuite/
* gnat.dg/bip_exception.adb, gnat.dg/bip_exception.ads,
gnat.dg/bip_exception_pkg.ads: New testcase.
From-SVN: r266115