Re: CVF 6.6C bug?

From: Richard Maine (nospam_at_see.signature)
Date: 04/20/04


Date: 20 Apr 2004 13:28:09 -0700


"James Giles" <jamesgiles@worldnet.att.net> writes:

> However, it works fine if the expression in the I/O list is
> enclosed in parentheses. The standard has the same rules
> for expressions everywhere, and doesn't require parentheses
> around expressions using defined operators.

Interesting. As a perhaps-related historical note, the standard
didn't always have the same rules for expressions everywhere.
In particular, there was a special rule for I/O lists. But it
was more the opposite of what you are seeing. Superfluous
parens around an expression were disallowed in I/O lists because
of a potential confusion with complex literal constants. Hmm.
Let me see if I can find it to make sure my memory isn't
playing tricks on me....

Uh oh. Dave? My memory is going...

I'm not finding it. What was I recalling. F66 maybe? Nope.
Hmm....Ah! There it is. Not quite what I recalled, but close
enough to restore my illusion of sanity. It isn't extra parens
around expressions, but extra parens in a list. F77 item 12 in
Appendix A2 (Conflicts with f66). F66 allowed parens in the I/O
list as in

  write(lun,1000) (x,y)

F77 disallows this because otherwise it is ambiguous whether

  write (*,*) (1.0,2.0)

is a single complex constant or two real constants with extra
parens in the list.

-- 
Richard Maine                       |  Good judgment comes from experience;
email: my first.last at org.domain  |  experience comes from bad judgment.
org: nasa, domain: gov              |        -- Mark Twain


Relevant Pages