-
Notifications
You must be signed in to change notification settings - Fork 11.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Flang] Support for passing procedure pointer, reference to a functio…
…n that returns a procedure pointer to structure constructor. (#86533) This PR fixes `not yet implemented: procedure pointer component in structure constructor` as shown in the following test case. ``` MODULE M TYPE :: DT PROCEDURE(Fun), POINTER, NOPASS :: pp1 END TYPE CONTAINS INTEGER FUNCTION Fun(Arg) INTEGER :: Arg Fun = Arg END FUNCTION END MODULE PROGRAM MAIN USE M IMPLICIT NONE TYPE (DT) :: v2 PROCEDURE(FUN), POINTER :: pp2 v2 = DT(pp2) v2 = DT(bar()) CONTAINS FUNCTION BAR() RESULT(res) PROCEDURE(FUN), POINTER :: res END END ```
- Loading branch information
1 parent
87519a2
commit 4998587
Showing
3 changed files
with
46 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters