[J3] [EXTERNAL] an amusing mistake
Malcolm Cohen
malcolm at nag-j.co.jp
Tue Aug 4 21:30:25 EDT 2020
I agree with Robert. Deleting it just sweeps the issue under the rug – it does not help anyone; not compiler writers, not users, not people trying to work out what was and was not allowed.
The fix is not terribly difficult – on the face of it, inserting “immediately before the entity-decl-list” before “in the” is sufficient.
Robert, could you write this up as an interp please? It will be F18/021.
Cheers,
--
..............Malcolm Cohen, NAG Oxford/Tokyo.
From: J3 <j3-bounces at mailman.j3-fortran.org> On Behalf Of Robert Corbett via J3
Sent: Wednesday, August 5, 2020 3:29 AM
To: General J3 interest list <j3 at mailman.j3-fortran.org>
Cc: Robert Corbett <rpcorbett at att.net>
Subject: Re: [J3] [EXTERNAL] an amusing mistake
The optional comma was present in FORTRAN 77,
which is as far back as the CHARACTER data type
goes. The constraint was added in Fortran 90,
when the form and function of declaration
statements were greatly expanded. In Fortran 90
and Fortran 95, the constraint was correct,
because the double-colon separator could not
appear in a expression. The syntax for array
constructors was extended in Fortran 2003 to
include an optional double-colon separator.
The constraint should have been modified in
Fortran 2003, or a different syntax should have
been chosen for array constructors.
I am surprised I did not notice the mistake
before. I studied the Fortran 2003 standard
very closely when I was still working.
Deleting the optional comma would make lots of
existing codes nonstandard. I would rather not
do that. I am slightly less opposed to doing
it now that I am retired and do not have to
field complaints from irate users.
Bob Corbett
On Tuesday, August 4, 2020, 9:21:36 AM PDT, Clune, Thomas L. (GSFC-6101) via J3 <j3 at mailman.j3-fortran.org <mailto:j3 at mailman.j3-fortran.org> > wrote:
Ditto.
On Aug 4, 2020, at 11:13 AM, Dan Nagle via J3 <j3 at mailman.j3-fortran.org <mailto:j3 at mailman.j3-fortran.org> > wrote:
Hi,
On Aug 4, 2020, at 09:10 , Bill Long via J3 <j3 at mailman.j3-fortran.org <mailto:j3 at mailman.j3-fortran.org> > wrote:
Perhaps a more reasonable solution would be to just move the optional comma to the Deleted List. (Hence deleting the constraint).
I can agree.
--
Cheers!
Dan Nagle
Disclaimer
The Numerical Algorithms Group Ltd is a company registered in England and Wales with company number 1249803. The registered office is: Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom. Please see our Privacy Notice <https://www.nag.co.uk/content/privacy-notice> for information on how we process personal data and for details of how to stop or limit communications from us.
This e-mail has been scanned for all viruses and malware, and may have been automatically archived by Mimecast Ltd, an innovator in Software as a Service (SaaS) for business.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.j3-fortran.org/pipermail/j3/attachments/20200805/1c5c3e04/attachment.htm>
More information about the J3
mailing list