]> git.ipfire.org Git - thirdparty/gcc.git/commit
Fortran : accepts pointer initialization of DT dummy args PR45337
authorMark Eggleston <markeggleston@gcc.gnu.org>
Wed, 10 Jun 2020 06:22:50 +0000 (07:22 +0100)
committerGiuliano Belinassi <giuliano.belinassi@usp.br>
Mon, 17 Aug 2020 16:17:32 +0000 (13:17 -0300)
commit557e5146ad481e52b3eae6128bde09dfd77533c9
treee7b9c436d0f81c409752363416555569d32dd6f9
parentf38ddda3e528585e9c0526d7b5e199d7106666ec
Fortran  : accepts pointer initialization of DT dummy args PR45337

Initialisation of a variable results in an implicit save attribute
being added to the variable.  The save attribute is not allowed for
variables with the dummy attribute set.  Initialisation should be
rejected for dummy variables.

2020-07-13  Mark Eggleston  <markeggleston@gcc.gnu.org>

gcc/fortran/

PR fortran/45337
* resolve.c (resolve_fl_variable): Remove type and intent
checks from the check for dummy.

2020-07-13  Mark Eggleston  <markeggleston@gcc.gnu.org>

gcc/testsuite/

PR fortran/45337
* gfortran.dg/pr45337_1.f90: New test.
* gfortran.dg/pr45337_2.f90: New test.
gcc/fortran/resolve.c
gcc/testsuite/gfortran.dg/pr45337_1.f90 [new file with mode: 0644]
gcc/testsuite/gfortran.dg/pr45337_2.f90 [new file with mode: 0644]