]> git.ipfire.org Git - thirdparty/gcc.git/commit
[Ada] Null procedures not allowed in protected definitions
authorpmderodat <pmderodat@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 11 Jan 2018 08:53:48 +0000 (08:53 +0000)
committerpmderodat <pmderodat@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 11 Jan 2018 08:53:48 +0000 (08:53 +0000)
commitcf1c2dd4641918d2d80d02fe4ce7e3bf2a185903
treec27152b758c5e0df86a26a394d7f3033aeccd6f7
parentfa189f81c17a2b8e77060e1184d87d606e44a52c
[Ada] Null procedures not allowed in protected definitions

The syntax rules do not allow null procedures in protected definitions. This
patch fixes a bug that accidentally allowed them.

2018-01-11  Bob Duff  <duff@adacore.com>

gcc/ada/

* par-ch9.adb (P_Protected_Operation_Declaration_Opt): Give an error if
a null procedure occurs in a protected definition.

gcc/testsuite/

* gnat.dg/protected_null.adb: New testcase.

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