Silverfrost Forums

Welcome to our forums

ftn95 handling of IO units?

21 Jun 2005 11:27 #203

Does FTN95 handle IO units in some unusual way? I'm testing the compiler by attempting to port over some code written using Sun's f95, and I'm getting a result that doesn't make sense to me. Specifically, I have an IO unit open for writing to an output file:

    open(unit=iounit2,file=tracename,status='unknown')
    write (*,*) 'Output file opened'

and then when I write to standard output further down in the code, it ends up in my output file instead. Am I doing something subtly wrong?

21 Jun 2005 11:30 #204

The value of iounit2 must not be 2 or 6. For simplicity user values for IO units should be greater than 6.

22 Jun 2005 9:12 #205

Aha, that'd be why. Reserved unit numbers seem to be compiler-dependent. Thanks!

Please login to reply.