]> git.ipfire.org Git - thirdparty/gcc.git/commit
[Ada] Reject violation of SPARK 6.1.4(12) with enclosing task unit
authorpmderodat <pmderodat@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 11 Jun 2018 09:18:56 +0000 (09:18 +0000)
committerpmderodat <pmderodat@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 11 Jun 2018 09:18:56 +0000 (09:18 +0000)
commitc1314460703d98f377074a206871eeba0a9f047e
treea3d2ce9fe0cc844a06a408b652444b43e60632a1
parentec7e01f008db5eaf9447fc67c7c503905129a87f
[Ada] Reject violation of SPARK 6.1.4(12) with enclosing task unit

SPARK 6.1.4(12) applies both to enclosing subprograms and enclosing task
units, but the latter was not correctly rejected.

2018-06-11  Yannick Moy  <moy@adacore.com>

gcc/ada/

* sem_prag.adb (Check_Mode_Restriction_In_Enclosing_Context): Adapt for
possible task unit as the enclosing context.

gcc/testsuite/

* gnat.dg/spark1.adb, gnat.dg/spark1.ads: New testcase.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@261421 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ada/ChangeLog
gcc/ada/sem_prag.adb
gcc/testsuite/ChangeLog
gcc/testsuite/gnat.dg/spark1.adb [new file with mode: 0644]
gcc/testsuite/gnat.dg/spark1.ads [new file with mode: 0644]