This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Odd error on redundant use of iso_fortran_env


All,

Is the following behavior a compiler bug?

$ cat use-intrinsic-module-twice.f90 
    use iso_fortran_env 
    print *, integer_kinds   
    call testsub
contains
  subroutine testsub
    use iso_fortran_env
    print * , integer_kinds
  end subroutine
end

$ gfortran use-intrinsic-module-twice.f90 
/var/folders/9_/nq83sd_5647315hnr42v8cqw0000gn/T//cc8CrVoi.s:116:Ignoring attempt to re-define symbol.

$ gfortran --version
GNU Fortran (MacPorts gcc7 7-20161204_0) 7.0.0 20161204 (experimental)

Interestingly, the “cc8CrVoi” string changes upon every invocation of the compiler.  I see the same behavior with gfortran 4.9, 5, 6, and 7.

The workaround is painless: eliminate the second instance of “use iso_fortran_env.”  Shall I submit a bug report?

Damian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]