I have some Fortran code that compiles with the gfortran, Cray, Intel and IBM compilers but not with PGI (v. 15.1).
I have an interface to some logging routines:
interface model_write_log module procedure write_log_a, write_log_ir, & write_log_i, write_log_r end interface subroutine write_log_r(fmtstr, fvar) use iso_fortran_env, only : output_unit ! access computing environment implicit none character(len=*), intent(in) :: fmtstr real(wp), intent(in) :: fvar
and some code that attempts to call the logging routine:
real(wp) :: chksum character(len=30) :: log_fmt ... chksum = 10.4 write(log_fmt, "((A))") "('ua checksum = ',E16.8)" call model_write_log(log_fmt, chksum)
I compile with -O3 only and get the error:
pgf90 -O3 -I../api_v1.0 -c nemolite2d.f90 PGF90-S-0155-Ambiguous interfaces for generic procedure model_write_log (nemolite2d.f90: 109)
Am I missing something here or is this a problem with the compiler?