| Re: Sun Studio 12, 'standard input' RECL question... |
|
 |
|
 |
|
 |
|
 |
Group: comp.lang.fortran · Group Profile
Author: J. F. CornwallJ. F. Cornwall Date: Jun 12, 2008 07:55
John Harper wrote:
> In article aioe.org>, dpb non.net> wrote:
>
>>glen herrmannsfeldt wrote:
>>
>>>dpb wrote:
>>>
>>>
>>>>J. F. Cornwall wrote:
>>>
>>>(snip)
>>>
>>>
>>>>>READ (*,'(A)') DBUFF
>>>
>>>(snip)
>>>
>>>
>>>>I don't know about Sun Studio and someone (Bob Corbett may see) surely
>>>>does. However, as a quickie, what does INQUIRE() for RECL tell you,
>>>>if anything?
>>>
>>>Is UNIT=* allowed for INQUIRE?
>
>
> No, presumably because INQUIRE wouldn't know whether you were asking
> about the input or output unit called *.
>
> The good news is that Sun Studio 12 f95 has implemented iso_fortran_env
> so you can discover the unsurprising fact that input_unit is 5.
> The bad news is that INQUIRE with that unit gives recl == 0, and
> when I tried to read a long string of characters with (A) format it
> was OK up to length 256 but not at 257.
I haven't had a chance to try putting an INQUIRE into the program (spent
last night in the basement watching tornadoes on local weather
radar...), but your experiment sounds like confirmation of the same
limit. We still do everything in fixed-format "F77" (yes, I know it's
really the f95 compiler). It would appear my best short-term option is
to tell the users they get 255 characters for a comment in this
particular application :-\
Thanks all
Jim
|