The relationship between a Cray pointee and its pointer is not in the symbol table entry, but instead in a per-scope map. Use this information to ensure that if a pointee/pointer is needed in the module file, so is its pointer/pointee. Fixes https://github.com/llvm/llvm-project/issues/130270.
20 lines
289 B
Fortran
20 lines
289 B
Fortran
! RUN: %python %S/test_modfile.py %s %flang_fc1
|
|
module m
|
|
contains
|
|
function f() result(ptr)
|
|
character :: str
|
|
pointer(ptr, str)
|
|
ptr = 0
|
|
end
|
|
end
|
|
|
|
!Expect: m.mod
|
|
!module m
|
|
!contains
|
|
!function f() result(ptr)
|
|
!integer(8)::ptr
|
|
!pointer(ptr,str)
|
|
!character(1_8,1)::str
|
|
!end
|
|
!end
|