Issue |
104796
|
Summary |
Flang rejects named constant of derived type in pure procedure
|
Labels |
flang
|
Assignees |
|
Reporter |
everythingfunctional
|
I documented the issue in [another repo](https://github.com/HPC-Bugs/reproducers/tree/main/compiler/Fortran/flang/constant-in-pure), but the following example is sufficient to reproduce the error.
```fortran
program example
type :: my_type
integer :: val
end type
print *, thing()
contains
pure function thing()
type(my_type) :: thing
type(my_type), parameter :: constant = my_type(42)
thing = constant
end function
end program
```
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs