https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122693
Bug ID: 122693
Summary: [PDT] all manner of tomfoolery
Product: gcc
Version: 16.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: fortran
Assignee: unassigned at gcc dot gnu.org
Reporter: damian at archaeologic dot codes
Target Milestone: ---
This one is so weird and I'm so exhausted after a long day in a long week in a
long month... that I'm running out of reasonable descriptions -- hence the
above summary. :)
At one point along the way to a minimal reproducer, I saw an ICE but I didn't
leave a sufficient number of bread crumbs to reproduce so I'm not sure of the
quickest path from here to there and therefore won't attempt to describe it:
$ cat reproducer.f90
module tensor_m
implicit none
type tensor_t(k)
integer, kind :: k = kind(0.)
end type
interface tensor_t
module function tensor(unused_stuff)
implicit none
real unused_stuff
type(tensor_t) tensor
end function
end interface
end module
use tensor_m
implicit none
contains
function test_passed()
logical test_passed
type(tensor_t), allocatable :: tensor_array(:)
real, parameter :: junk = 0.
tensor_array = [tensor_t(junk)]
test_passed = .false.
end function
end
$ gfortran -c reproducer.f90
reproducer.f90:26:16:
26 | test_passed = .false.
| 1
Error: ‘test_passed’ at (1) is not a variable
reproducer.f90:25:33:
25 | tensor_array = [tensor_t(junk)]
| 1
Error: Symbol ‘junk’ at (1) has no IMPLICIT type
$ gfortran --version
GNU Fortran (GCC) 16.0.0 20251114 (experimental)