r274446 - in /trunk/gcc: ada/ChangeLog ada/sem_...
pmderodat@gcc.gnu.org
pmderodat@gcc.gnu.org
Wed Aug 14 09:50:00 GMT 2019
Author: pmderodat
Date: Wed Aug 14 09:50:46 2019
New Revision: 274446
URL: https://gcc.gnu.org/viewcvs?rev=274446&root=gcc&view=rev
Log:
[Ada] Illegal selection of first object in a task type's body not detected
The compiler was improperly allowing selection of an object declared
within a task body when the prefix was of the task type, specifically in
the case where the object was the very first declared in the body
(selections of later body declarations were being flagged). The flag
Is_Private_Op was only set at the point of the first "private"
declaration of the type in cases where the first declaration's name
didn't match the selector.
2019-08-14 Gary Dismukes <dismukes@adacore.com>
gcc/ada/
* sem_ch4.adb (Analyze_Selected_Component): In the case where
the prefix is of a concurrent type, and the selected entity
matching the selector is the first private declaration of the
type (such as the first local variable in a task's body), set
Is_Private_Op.
gcc/testsuite/
* gnat.dg/task5.adb: New testcase.
Added:
trunk/gcc/testsuite/gnat.dg/task5.adb
Modified:
trunk/gcc/ada/ChangeLog
trunk/gcc/ada/sem_ch4.adb
trunk/gcc/testsuite/ChangeLog
More information about the Gcc-cvs
mailing list