07-188 To: J3 From: Van Snyder Subject: Comments on Clause 5 Date: 2007 April 23 1 Edits Edits refer to07-007r1. Page and line numbers are displayed in the margin. Absent other instructions, a page and line number or line number range implies all of the indicated text is to be replaced by associated text, while a page and line number followed by + (-) indicates that associated text is to be inserted after (before) the indicated line. Remarks are noted in the margin, or appear between [ and ] in the text. [87:14] ------------------------------------------------------------------ [Editor: Replace "[ , ] . . . " by "[ , ]" if you agree it's clearer.] [88:33] ------------------------------------------------------------------ [Editor: Insert "or intrinsic" after "generic".] [88:37] ------------------------------------------------------------------ [Why pussy-foot around automatic co-arrays with the SAVE attribute in C528? Editor: Insert "a co-array or" after "be".] [89:8-9] ----------------------------------------------------------------- [Editor: Replace "the variable . . . specified" by "default initialization is specified for a direct component of the type of the variable".] [90:29] ------------------------------------------------------------------ [Editor: Remove the parentheses around "9.5.2.5".] [92:22-31] --------------------------------------------------------------- [Using "shall" in the list is wrong. Editor: Replace the list by the following:] · If its base ob ject is a pointer or assumed-shape array, it has the CONTIGUOUS attribute. · It is not the real or imaginary part of an array of type complex. · Its designator does not contain a . [Better yet: · If its designator contains a the first either does not appear or is an initialization expression with the value 1, and the second does not appear.] · It does not have a vector subscript. · Only its final has nonzero rank. · If a appears it satisfies the following conditions: ­ A does not appear. [Better yet: ­ If appears it is specified by an initialization expression with the value 1.] ­ If any is a , it is not followed by a . ­ Each but the last consists of a single colon [, or two colons and a ,] with no s. [93:17] ------------------------------------------------------------------ [Editor: Insert "or submodule" after "module".] [93: Note 5.11] ---------------------------------------------------------- [Editor: If C513 is amended explicitly to prohibit automatic co-arrays, replace "This . . . example, the" by "The".] [94:11-12] --------------------------------------------------------------- [C530 duplicates C513, doesn't cover common (which is covered by C598), and prohibits using length type parameters within a type definition. Editor: Delete C530.] [94:23-24] --------------------------------------------------------------- [The sentence at [95:2] is clearer. It would also be clearer if it appeared before the lower bound value is referenced. Editor: Delete "If the . . . is 1." and copy the sentence "If appears . . . is 1." at [95:2] before "The value" at [94:19].] [95:5-6] ----------------------------------------------------------------- [The part about rank duplicates [93:2]. The part about bounds and shape duplicates [95:16-18]. Editor: Delete "and a specified . . . association."] [95:7-8] ----------------------------------------------------------------- [The sentence about bounds and shape is defective by not mentioning argument association, and dupli- cates [95:19-23] anyway. Editor: Delete "Its bounds . . . target."] [96:13] ------------------------------------------------------------------ [Editor: Replace "be written" by "appear" because there's no WRITE statement under discussion.] [97:3] ------------------------------------------------------------------- [There's no need to put "bounds" into possessive case; it's a perfectly good adjective. Editor: Delete the apostrophe.] [101: Note 5.20] --------------------------------------------------------- [It's not obvious that the PROTECTED attribute "ensures" anything. Editor: Perhaps "specifies" is a better word than "ensures" in the penultimate line of the note.] [102:10] ----------------------------------------------------------------- [Editor: Delete "accessible".] [102: Note 5.23] --------------------------------------------------------- [Editor: Replace "will have" by "has" in the first line. Pointers don't "point to" they are "associated with". Editor: Replace "point only to" by "only be associated with" in the third line.] [103:5] ------------------------------------------------------------------ [Editor: Delete "necessarily".] [105:1-2] ---------------------------------------------------------------- [Editor: Replace "If " by "A". Replace "has been . . . definition" by "for which default initialization is specified for any direct component". Delete ", it". Shouldn't this be a constraint?] [105:4] ------------------------------------------------------------------ [Editor: Replace "has not been" by "is not".] [105:5-6] ---------------------------------------------------------------- [Editor: Replace "An" by "The array propreties of an" and replace "have had its array properties" by "be".] [105:23] ----------------------------------------------------------------- [Editor: Replace "and" by "or".] [106:2] ------------------------------------------------------------------ [Editor: Replace "have been" by "be" and replace "made accessible" by "accessed".] [106:12-14] -------------------------------------------------------------- [Editor: Replace "have been" by "be" and replace "made accessible" by "accessed".] [110:16] ----------------------------------------------------------------- [Editor: Replace "If " by "Otherwise if ". As it stands, it contradicts IMPLICIT NONE.] [110:21,23] -------------------------------------------------------------- [Editor: Replace "made accessible" by "accessed", insert a comma after "host association" and replace "has been" by "be".] [115:24] ----------------------------------------------------------------- [Editor: Replace "have no" by "not have a direct component with".] [117:32] ----------------------------------------------------------------- [Editor: Replace "with" by "for which any direct component has".] 2 Questions and comments without edits [4.5.4.5] ---------------------------------------------------------------- Would it be clearer to put the prohibitions and constraints relating default initialization, explicit initial- ization [89:8-9, 105:2], common [115:24], and equivalence [117:32] into subclause 4.5.4.5? [91: Note 5.5] ----------------------------------------------------------- How can the ASYNCHRONOUS attribute both disable and facilitate code motion optimizations? [93: Note 5.10] ---------------------------------------------------------- I can't find normative support for the second sentence in note. If it exists it would be helpful to reference it. [97:14-15] --------------------------------------------------------------- C537 appears to prevent using a length parameter within an expression that specifies a co-bound of a co-array component of a parameterized derived type. How about copying C513: C537 (R520) A co-array with a or that is not an initialization expression shall not be a local variable of a main program, module or submodule. [5.3.7.8] ---------------------------------------------------------------- There's no prohibition against the product of the first rank-1 co-extents being greater than the number of images. What happens in that case? [108:10, 112:20]---------------------------------------------------------- It seems that one can declare a variable with an attribute statement, say DIMENSION or TARGET, and then declare it with a that gives it a type different from the type the implicit rules would imply, unless the attribute statement is a PARAMETER statement. Shouldn't this be done by a constraint in 5.2.1? Something like C504a If an entity is declared by a statement other than a the shall confirm the type and type parameters the ob ject would have according to the implicit typing rules (5.5). Then delete "If . . . implicitly (5.5)." at [108:10-12] and delete "If a namelist . . . parameters." at [112:20-22]. [5.2.3, 5.3-5.4] --------------------------------------------------------- It would be easier to use clause 5 for reference, and it would be a tiny bit shorter, if the material on each attribute declaration statement were in the same subclause as the attribute itself, and the material on the DATA statement were a subclause of 5.2.3. Most subclause headings would have "and statement" added, e.g. ALLOCATABLE attribute and statement. [5.7.3]------------------------------------------------------------------- Should 5.7.3 be constraints?