This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Ada] No_Return procedures in renaming declarations.


This patch implements legality rule in 6.5.1 (7/2): if a renaming as body
completes a nonreturning procedure declaration, the renamed procedure must
be nonreturning as well.  Previously GNAT only produced a warning in such
cases.

Tested in ACATS test B651002.

Tested on x86_64-pc-linux-gnu, committed on trunk

2017-09-06  Ed Schonberg  <schonberg@adacore.com>

	* sem_ch6.adb (Check_Returns): Clean up warnings coming from
	generated bodies for renamings that are completions, when renamed
	procedure is No_Return.
	* sem_ch8.adb (Analyze_Subprogram_Renaming): Implement legality
	rule in 6.5.1 (7/2): if a renaming is a completion of a subprogram
	with No_Return, the renamed entity must be No_Return as well.

Attachment: difs
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]