(j3.2006) Locality problems not repaired at Garching
Van Snyder
Van.Snyder
Fri Jul 14 21:22:44 EDT 2017
On Sat, 2017-07-15 at 09:20 +0900, Malcolm Cohen wrote:
> <<<
> If an implicitly-declared
> variable appears only within a BLOCK construct (or several disjoint
> ones), is it a construct entity of that (those) BLOCK construct(s)?
> >>>
>
> Obviously not, since we state
> "An entity that is explicitly declared in the specification part of
> a BLOCK construct, other than only in ASYNCHRONOUS and VOLATILE
> statements, is a construct entity."
> Note that this does not include implicitly-declared entities.
According to 8.7p4
"The data entity is treated as if it were declared in an
explicit type declaration; if the outermost inclusive scope in
which it appears is not a type definition, it is declared in
that scope, otherwise it is declared in the host of that scope."
implicitly-declared variables that appear only in BLOCK constructs,
which are not type definitions, are treated as if they were explicitly
declared within those constructs. If we meant that implicitly-declared
variables that appear only in BLOCK constructs are not explicitly
declared in the outermost scope in which they appear, i.e., are not
construct entities, 8.7p4 should have included both type definitions and
BLOCK constructs in the conditions under which they are declared in the
host of the scope. Adding that now would be an incompatibility that
might invalidate existing programs.
Amending 19.4p1 so as not to appear to conflict with 8.7p4 might be an
incompatibility that might affect processors, but not existing programs.
Processors accept implicitly-typed variables that are explicitly
declared in, for example, DIMENSION statements. It is impossible to
detect whether ones that are implicitly typed and not explicitly given
any other attributes are or are not construct entities, except maybe by
looking at generated code.
More information about the J3
mailing list