J3/99-163r1 Date: 3rd June 1999 To: J3 From: Malcolm Cohen Subject: Unresolved issue 130 1. Introduction In several places there is some confusion between "specifications", "declarations", and "specification statements". 2. Discussion (i) The problems have arisen because we do not have a term for a statement that is purely a declaration - is much too narrow, and so (perhaps surprisingly) is (e.g. it misses out PARAMETER). There are examples in Annex C of long-standing mistakes (calling PARAMETER a specification statement). Maybe we should make up a name for this? declarative-construct? I note that using "specification statement" for this instead of the narrow meaning occurs in several places through the standard! (ii) BTW, is "nonkind type parameter value" ok? I presume so, though I don't see anything like a definition of what this would mean (I know what *I* think it means!) I'll leave this one alone. (iii) [261:42+] says "The local identifier of an entity made accessible by a USE statement may appear in no other specification statement that would cause any attribute (5.1.2) of the entity to be respecified in the scoping unit that contains the USE statement, except that it may appear in a PUBLIC or PRIVATE statement in the scoping unit of a module and it may be given the ASYNCHRONOUS or VOLATILE attribute." So it is ok to re-specify its value in a PARAMETER statement then? I think not - this ought to be fixed. Also - if it does not possess the POINTER attribute, putting it in a POINTER statement would not be "respecifying" the attribute! (iv) In 5.5 we say that "A namelist group object shall either be accessed by use or host association or shall have its type, type parameters, and shape specified by previous specification statements in the same scoping unit or by the implicit rules in effect for the scoping unit." Which means that REAL FUNCTION I() NAMELIST/NL/I is not legal. This should really be an F95 interp since the standard is not, I think, actually contradictory or ambiguous - it just says the wrong thing! But since we are not doing interp processing I am proposing to fix it in F2002. 3. Edits {Fix incorrect Note: (i) is used in all of the "declarative constructs", including procedure headings; (ii) is only used in array constructors, not structure constr.} [69:27] Change "specification" to "non-executable" Change "a constructor" to "an array constructor". {Revert wording to be more like the previous version...} [72:31] Change "In a declaration, an array bound or nonkind type parameter value" To "A in an or a corresponding to a nonkind type parameter in a " [72:32] Change "provided the expression" to "provided it" {Delete the J3 Note.} [73:1-14] Delete. {Fix NAMELIST} [99:6] After "specification statements" insert "or the procedure heading". {Try to fix USE association to prohibit what mere mortals mean by "local declaration" of USE-associated names.} [261:43] Change "specification" to "nonexecutable" Change "respecified" to "specified". {Or should we just delete the word "specification" and change "respecified" to "explicitly specified"? I don't think so.} {Alternative: list everything that is prohibited - the trouble with this is that although it is then crystal-clear it is quite long - see the list in 14.6.1.3 - it has 15 items.}