[Ada] Wrong accessibility on 'Access of formal in call

Pierre-Marie de Rodat derodat@adacore.com
Mon Jul 27 08:05:52 GMT 2020


This patch fixes a bug in the compiler whereby taking 'Access on a
component of an anonymous access formal parameter and using such an
expression as an actual in a call where the corresponding formal is also
an anonymous access type will cause dynamic accessibility checks within
the callee function to not be performed.

This is also an iterative patch for overall accessibility work.

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

gcc/ada/

	* exp_ch6.adb (Expand_Call_Helper): Modify addition of the extra
	accessibility parameter to take into account the extra
	accessibility of formals within the calling subprogram.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.diff
Type: text/x-diff
Size: 4695 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20200727/dc8e65bd/attachment-0001.bin>


More information about the Gcc-patches mailing list