Re: placement of implicit none
From: Richard E Maine (nospam_at_see.signature)
Date: 01/27/05
- Next message: glen herrmannsfeldt: "Re: A newbie question"
- Previous message: Kobrinsky: "Re: [Fortran77] stops writing files"
- In reply to: beliavsky_at_aol.com: "placement of implicit none"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 27 Jan 2005 09:36:54 -0800
In article <1106844627.076977.312830@f14g2000cwb.googlegroups.com>,
beliavsky@aol.com wrote:
> Why does Fortran require the "implicit none" statement to follow any
> "use" statements? Could this constraint be removed?
I couldn't say for sure. I seem to recall reconstructing a reason that
made sense from at least one viewpoint, because I've run into the same
thing... hmm... Oh yes, that was probably it...
Implicit statements in general can depend on other names, including
possibly ones imported via USE. A bit obscure and I don't recall ever
seeing such a thing in actual code, but it can happen in principle. USE
statements can't ever depend on anything else - there's just nothing in
their syntax that could. So it probably simplified life to require that
order instead of detailing the conditions under which the other order
works.
> I want "implicit none" to appear as early as possible in a code.
Me too. In particular, I'd like to consider "implicit none" as almost a
part of the syntax of a module statement. Not literally, but
conceptually, in that it is just automatically how you start a module
before you get to any details about what is in the module. Almost all of
my implicit none statements are at the top of modules, since that "flows
down" to (almost) everything in the module, and almost everything I do
is in modules.
Well, what I'd really have liked is for implicit none to be the default
in free source form, but my comment about that during the f90 public
review didn't get accepted. Some of my others did, but not that one.
I wouldn't think it a very big deal to allow at least the "implicit
none" form before USE statements. For that matter, I don't see that it
would be very hard to allow that ordering more generally; the potential
problem cases aren't hard to describe. (Some existing words might even
almost be enough, though I haven't checked).
Seems to me like a reasonable and trivial thing to ask for in f2003+.
Except that I'm loath to ask for anything at all because my personal
opinion is that J3 is already way overboard with too many features
proposed for f2003+. It seems widely agreed (not universally, but by a
good majority anyway) that f2003+ needs to be a minor revision
comparable to f95, concentrating on "fixup" of f2003, which was a big
enough revision that it is bound to need substantial fixup work just
like f90 did. However, while this seems agreed in principle, some people
obviously have drastically different viewpoints on what constitutes
"minor" and how much work features will take. I think that a lot of the
proposals labeled as minor are far bigger deals than their proponents
are arguing. I view the situation as bad enough that I just have trouble
with throwing in ideas that I like and arguing that "mine are actually
minor, unlike those others."
At times I worry that one or two people, by submitting more proposals
than I consider reasonable, have essentially "clogged the pipeline" and
effectively frozen out other ideas as a result. But then, I can't
reasonably complain about someone working hard and diligently on what
they think will be improvements, can I? This all just my personal
musings and viewpoint, of course.
-- 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
- Next message: glen herrmannsfeldt: "Re: A newbie question"
- Previous message: Kobrinsky: "Re: [Fortran77] stops writing files"
- In reply to: beliavsky_at_aol.com: "placement of implicit none"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|