AW: Remaining Characters (Q)
De-Groof, Vincent
Vincent.DeGroof@hilti.com
Wed Mar 13 12:45:00 GMT 2019
Hi Thomas, Hi Steve,
Thanks for the confirmation. I'll first need to fully understand what my code is doing at this position. I'll have a look if Thomas's suggestion is working for me, too.
Best regards,
Vincet
-----Ursprüngliche Nachricht-----
Von: Thomas Koenig [mailto:tkoenig@netcologne.de]
Gesendet: Dienstag, 12. März 2019 22:55
An: De-Groof, Vincent; fortran@gcc.gnu.org
Betreff: Re: Remaining Characters (Q)
Hi Vincent,
> Apparently, gfortran does not recognize 'Q' descriptor. Is there an alternative for this in gfortran?
There is no direct alternative, but as it happens, I recently fixed this
in some old code.
Instead of
read (10,1000) i1, i2
1000 format (q, i20)
I used an internal unit instad, something like
character(len=80) line
read (10,'(A)') line
i1 = len_trim(line)
read (unit=line,fmt='(I20)') i2
which worked for my case.
Maybe we should add the Q edit descriptor to the gfortran manual's
chapter dealing with unsupported extensions.
Regards
Thomas
More information about the Fortran
mailing list