https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93483
Mikael Morin <mikael at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |mikael at gcc dot gnu.org
--- Comment #11 from Mikael Morin <mikael at gcc dot gnu.org> ---
(In reply to Steve Kargl from comment #8)
> If regtesting complete ok, and Mikael doesn't find any additional
> problems. Please commit.
Unfortunately, I think there is one problem.
Generally speaking, I don't like doing too much at parsing stage, and
especially simplifying. It's too early in my opinion.
Here is an example, where the array simplifies using the host-associated
parameter value instead of calling the contained function with the same name
hiding it. It is admittedly somewhat artificial.
module m
implicit none
integer, parameter :: a(*) = [ 7, 11 ]
contains
subroutine bug
real :: b(1)
b = [ real :: (a(1)) ]
print *, b
if (any(b /= [ 14. ])) stop 1
contains
function a(c)
integer :: a, c
a = c + 13
end function a
end subroutine bug
end module m
program p
use m
call bug
end program p