Peter Klausler 83ca78deb9
[flang] Emit "raw" name for procedure interface in module file (#83915)
Save both the raw procedure interface symbol as well as the result of
passing it through GetUltimate() and BypassGeneric() in symbol table
entries with ProcEntityDetails. The raw symbol of the interface needs to
be the one used for emitting procedure symbols to module files.

Fixes https://github.com/llvm/llvm-project/issues/83836.
2024-03-05 12:00:46 -08:00

30 lines
475 B
Fortran

! RUN: %python %S/test_modfile.py %s %flang_fc1
module mod0
interface proc
module procedure proc
end interface
contains
subroutine proc
end
end
module mod1
use mod0,renamed_proc=>proc
procedure(renamed_proc),pointer :: p
end module
!Expect: mod0.mod
!module mod0
!interface proc
!procedure::proc
!end interface
!contains
!subroutine proc()
!end
!end
!Expect: mod1.mod
!module mod1
!use mod0,only:renamed_proc=>proc
!procedure(renamed_proc),pointer::p
!end