[Ada] Spurious tampering check failure
This patch modifies the transient scope mechanism to create a scope when the
condition of an iteration scheme returns a controlled result or involves the
secondary stack. As a result, a while loop which iterates over a container
properly manages the tampering bit at each iteration of the loop.
2018-05-31 Hristian Kirtchev <kirtchev@adacore.com>
gcc/ada/
* exp_ch7.adb (Find_Transient_Context): An iteration scheme is a valid
boudary for a transient scope.
gcc/testsuite/
* gnat.dg/tampering_check1.adb, gnat.dg/tampering_check1_ivectors.ads,
gnat.dg/tampering_check1_trim.adb, gnat.dg/tampering_check1_trim.ads:
New testcase.
From-SVN: r261006