Re: strange linking problem



To make this even stranger, I found that the following modifications to
Parameters.F90 and Main.F90 make both version of the program work


in file Parameters.F90:

MODULE Parameters
IMPLICIT NONE
Character (len=100) :: test = "This is a test"
CONTAINS
subroutine nop ()
return
end subroutine nop
END MODULE


in file Main.F90:

PROGRAM Main
USE Parameters
IMPLICIT NONE

write (*, *) "printing test: ", test

END PROGRAM Main

subroutine nopMain ()

use Parameters
implicit none

call nop ()
return

end subroutine nopMain

.