- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I have encountered a problem with the attached code. I have reduced it as far as
possible, but the error message disappears when I further simplify the code a bit.
I am using Intel Fortran 11.1 but the problem occurs in 12.0.3 as well.
The compiler claims there is no specific subroutineat line 89 of the code, whereas
gfortran is completely happy with and if I use the specific name (get_procedure_global)
instead of the generic name,Intel Fortran is happy too.
Background: I am using theoriginalto dynamically load libraries and subroutines therein.
It seems to be the procedure _component_ that triggers the error. If I change the
argument to proc, with the declaration:
procedure(creation_procedure), pointer :: proc
call get_procedure( dynlib, 'create_prng', proc, success )
the compiler is happy again.
Is this a compiler bug?
Regards,
Arjen
I have encountered a problem with the attached code. I have reduced it as far as
possible, but the error message disappears when I further simplify the code a bit.
I am using Intel Fortran 11.1 but the problem occurs in 12.0.3 as well.
The compiler claims there is no specific subroutineat line 89 of the code, whereas
gfortran is completely happy with and if I use the specific name (get_procedure_global)
instead of the generic name,Intel Fortran is happy too.
Background: I am using theoriginalto dynamically load libraries and subroutines therein.
It seems to be the procedure _component_ that triggers the error. If I change the
argument to proc, with the declaration:
procedure(creation_procedure), pointer :: proc
call get_procedure( dynlib, 'create_prng', proc, success )
the compiler is happy again.
Is this a compiler bug?
Regards,
Arjen
Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I was trying to see if the problem still showed up in a current compiler, but there is a missing module prng_class.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Oops, it worked for me because the mod file was still present. Here is the
source code for that module:
source code for that module:
! prng_class.f90 --
! Module defining the generic type for pseudo-random number
! generators (PRNG). Used by all specific PRNG implementations
!
module prng_class
implicit none
type, abstract :: prng
! No data
contains
procedure(get_next), deferred :: get
end type
abstract interface
real function get_next( params )
import :: prng
class(prng) :: params
end function get_next
end interface
end module prng_class
Regards,
Arjen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ah, good to hear that.
Regards,
Arjen
Regards,
Arjen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I can reproduce the problem - at first glance it looks like a compiler bug, but I am not sure. Investigating...
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page