From jwagener@amoco.com  Sat Oct 14 01:04:06 1995
Received: from interlock.amoco.com (interlock.amoco.com [192.195.167.2]) by dkuug.dk (8.6.12/8.6.12) with SMTP id BAA12006 for <sc22wg5@dkuug.dk>; Sat, 14 Oct 1995 01:03:48 +0100
From: jwagener@amoco.com
Received: by interlock.amoco.com id AA12545
  (InterLock SMTP Gateway 3.0 for sc22wg5@dkuug.dk);
  Fri, 13 Oct 1995 19:03:33 -0500
Message-Id: <199510140003.AA12545@interlock.amoco.com>
Received: by interlock.amoco.com (Protected-side Proxy Mail Agent-3);
  Fri, 13 Oct 1995 19:03:33 -0500
Received: by interlock.amoco.com (Protected-side Proxy Mail Agent-2);
  Fri, 13 Oct 1995 19:03:33 -0500
Received: by interlock.amoco.com (Protected-side Proxy Mail Agent-1);
  Fri, 13 Oct 1995 19:03:33 -0500
X-Openmail-Hops: 1
Date: Fri, 13 Oct 95 19:00:42 -0500
Subject: suggested replacement for 2 of 7
Mime-Version: 1.0
To: sc22wg5@dkuug.dk
Content-Type: text/plain; charset=US-ASCII; name="Text_1"
Content-Transfer-Encoding: 7bit

     To WG5:
     
     Following is a suggested replacement for CD ballot comments 2 of 7 
     that Miles recently distributed.  Several minor errors are corrected 
     in this version, and the items are placed in page order.  This message 
     contains items up to page 300; a subsequent message will have items 
     from page 300 on.
     
     
     Jerry Wagener, for the US
     
     ==============================================
     
     Quality Improvements
     --------------------
     
     [xv:30] add text following [xv:30]
     "(Note: this does not apply to pointers, only arrays declared with the 
     ALLOCATABLE attribute.)"  
     
     [xvii:3] change "of all terms" to "of principal terms"
     
     [3:15]  change to read "Real, double precision, and pointer DO control 
     variables,"
     
     [3:25]     Add "MAXVAL, MINVAL, PRODUCT, SUM " to list.  [Editor is 
     given discretion to reorder list.]
     
     [3:35+]   add 
     "(4)  This standard requires that an object with the TARGET attribute 
     become storage associated only with another object that has the TARGET 
     attribute.  This restriction did not apply in Fortran 90."
     
     [9:5] section 2.1, change "is described in 1.6.2" to
      ", assumed rules, and syntax conventions are
      described in 1.6.2 through 1.6.4".
     [13:43]  delete sentence "USE statements, if any.... "
     
     [14:16-17]  add a second note to the table
     "Note:  derived type definitions are also scoping units, but they do 
     not contain any of the above statements, and so have not been listed 
     in the table."
     
     [14:16-17]  in the footer of the Table 2.2, move "The scoping unit of 
     a module does not include  any  module  subprograms  that the module 
     contains." into a note.  
     
     [15:20] Section 2.4.1.2, 3rd sentence
      change "(4.4.5)" to "(7.5.1.5)"
     
     [17:27]  change "or following pointer association with a disassociated 
     pointer" to ",  following  pointer  association with a disassociated 
     pointer, or initially through pointer initialization."
     
     [25:4] Section 3.3, 2nd paragraph,
      change "(10.7)" to "(10.2.1)"
     
     [30:24]  delete 
     
     [30:26]    change sentence to read "An array has type and type 
     parameters..."
     
     [34:27] section 4.3.1.3, after "value." add:
      "The kind type parameter of an approximation method
      is returned by the intrinsic inquiry function
      KIND (13.14.52)."
     
     [38:11] (Brian's 41-42), Section 4.4, penultimate paragraph
      add at the end of the paragraph:
      "If a component has default initialization, it is
      not required that default initialization be specified
      for other components of the derived type." 
     
     [39:38] Section 4.4.1, 2nd paragraph after constraints,
      1st sentence, change "for a component" to
      "for a non-pointer component"
     
     [39:42]  2nd paragraph after constraints, 4th sentence, change "If an 
     
     [42:1] Note that this text is being moved into a NOTE just below.
      section 4.1.1, [42:1],
      change "of the type of which it is a component"
      to "of that derived type"
     
     [42:1-3] Section 4.4.1, text ahead of 10th note (note 4.26)
      Make the text part of the 10th note.
     
     [42:12] Section 4.4.1, text ahead of 11th note (note 4.27)
      Delete this sentence.
     
     [42:34] Section 4.4.1, text ahead of 13th note (note 4.29)
      Make the text part of the 13th note.
     
     [43:1] Section 4.4.1, text ahead of last note (note 4.30)
      Make the text part of the last note.
     
     [44:28+]  add as a new note:
     "The requirement that the two types have the same name applies to the 
     <type-name> of the respective <derived-type-stmt>, not to a local name 
     introduced via renaming in a USE statement."
     
     [45:29] (array constructors), insert to read "a nonpointer named .."
     
     [46:25] Section 4.5, penultimate note (4.38)
      Change "(20, `SMITH')" to "(40, `SMITH')"
     
     [48:42-45]  delete this note
     
     [49:22]  add to the end of this paragraph:
     "Use of =>NULL() in a scoping unit is a reference to the intrinsic 
     function NULL."
     
     [49:36] section 5.1 [49:36], move this line to be after line 32
      in the same note.
     
     [53:16]  change to read "shall neither be defined nor become 
     undefined."; change [205:14] to read the same.
     
     [53:27] section 5.1.2.3, [53:27],
      change "12.5.2.1, 12.5.2.2, 12.5.2.3" to
      "12.4.1.1, 12.4.1.2, 12.4.1.3"
     
     [53:39] Section 5.1.2.4, 1st paragraph, penultimate sentence
      Before "declaration" insert "type"
     
     [53:41] (Brian's 53:40), Section 5.1.2.4, end of 1st paragraph.
      Add
      "The DIMENSION attribute alternatively may be specified in the |
      specification statements DIMENSION, ALLOCATABLE,
      POINTER, TARGET or COMMON." |
     
     [61:11] (data statement implied do), insert to read "a nonpointer 
     named .."
     
     [61:43]  add to first sentence to read "...and scalar variables, 
     referred to as "sequence of variables" in subsequent text."
     
     [62:5]  change "sequence of scalar variables" to "sequence of 
     variables"
     
     [62:8]  change "sequences of scalar variables" to "sequence of 
     variables"
     
     [62:9] change 'initial value' to 'initial value or NULL()'
     
     [62:11-12] replace the sentence starting on line 11 with:
      "If an object is of type character, the corresponding
      <data-statement-constant> shall be of the same type
      and kind. If an object is of type logical, the
      corresponding <data-statement-constant> shall be of
      the same type."
     
     [62:17] (Brian's 32:10-33), section 5.2.10,
      add the following before [62:17-], as its own paragraph:
      "A <data-statement-constant> that is a
      <boz-literal-constant> is treated as if the
      constant were an <int-literal-constant> with the 
      maximum <kind-param> supported by the processor."
     
     [62:17] after "A <data-stmt-constant>" add ", other than NULL(),".
     
     [63:26]  change "for the name of that function subprogram" to "for the 
     name of the result variable of that function subprogram"
     
     [66:32]  add a constraint [66:32+]
     "Constraint: A substring-range shall not be empty." 
     
     [66:46+]  add at the end of the existing note as a new paragraph :
     "Further rules on the interaction of EQUIVALENCE statements and 
     default initialization are given in 14.6.3.3."
     
     [71:34] after "parameters" add
      " (except for <boz-literal-constant>s)"
     
     [73:30+] (Brian's 73:37+)
      add this note after the existing note on page 73:
     
      "The syntax rules are structured such that a <data-ref>
      that ends in a component name without a following
      subscript list is a structure component, even when other
      component names in the <data-ref> were followed by a
      subscript list. A <data-ref> that ends in a component
      name with a following subscript list is either an array
      element or an array section. A <data-ref> where one
      <part-ref> has non-zero rank, and that ends with a
      substring range, is an array section, but if all
      <part-ref>s are of rank zero, then that <data-ref>
      with the trailing substring range is a substring."
     
     [77:39-40]  replace with
     "A bound in an <allocate-shape-spec> shall not be an expression 
     containing any reference to any <allocate-object> or the 
     <stat-variable>, or a subobject of either, in the same ALLOCATE 
     statement."
     
     [78:4]  after "appears" add ", nor shall it depend on any 
     <allocate-object> or subobject of an <allocate-object> allocated in 
     the statement."
     
     [80:9+]  add  "A <pointer-object> shall not contain any references to 
     another <pointer-object> or subobject of a <pointer-object> in the 
     NULLIFY statement."
     
     [80:14+]  add  "An <allocate-object> shall  not reference any other 
     <allocate-object> or the <stat-variable>, or a subobject of either, in 
     the same DEALLOCATE statement."
     
     [80:15]  after "statement" add ", nor shall it depend on any 
     <allocate-object> or subobject of an <allocate-object> deallocated in 
     the statement."
     
     [93:17]  add "...is not an statement function, does not have a dummy 
     procedure argument, "
     
     [94:8]  add ":" at the end of "and where each argument of the function 
     is"; same to the 2 same lines in 7.1.6.1
     
     [94:20+] (Brian's 68:20) Paper 95-186 answers this for Fortran 90,
      /edit should apply the same edits (in 007r1, it goes
      after [94:20+])
      EDITS: see 95-186, adapt to 007r1
     
     [106:22]  change "an assumed" to "a whole assumed".
     
     [109:20-21] section 7.5.1.6: change the note to normative text, and
      in the text of the note, change
      "may not both be numeric, both be logical, or both be" |
      to
      "shall not both be numeric nor both be logical. The
      types and kinds of <X sub 1> and <X sub 2> shall not
      both be" |
     
     [111:33] section 7.5.3.2, change "a small" to "the following"
     
     [113:15] (FORALL), insert to read "a nonpointer named .."
     
     [113:36+] (Brian's 115 36+) add a note (section 7.5.4.1):
      "An assignment statement that is a FORALL body construct
      may be a scalar or array assignment statement, or a
      defined assignment statement. The variable being
      defined should use each index name in the
      <forall-triplet-spec-list>. For example,
      FORALL (I = 1:N, J = 1:N)
      A(:, I, :, J) = 1.0 / REAL(I+J-1)
      END FORALL
      broadcasts scalar values to rank two submatrices of A."
     
     [114:46] m1, m2, and m3 are not the user specified expressions.
      They are computed from the user specified expressions as
      described later in the paragraph. However, the following
      edits are needed:
     
     [114:46-115:5] indent the paragraph and number the
      paragraph (we'll add a 2nd paragraph below)
      (i.e. make the paragraphs a list).
     
     [114:46-115:5] All the subscripted "m"s, "k" and "max"
      should be in italics.
     
     [115:2] Start a new paragraph with the sentence that
      starts with "Let". This paragraph is also indented and
      is item 2 in the list. The last line of the paragraph
      is 115:5, so don't indent or number [115:6-7].
     
     [116:11-12] (Brian's 116:12) section 7.5.4.2.3,
      replace lines 11-12 with
      "Computations that would otherwise cause error conditions
      can be avoided by using an appropriate <scalar-mask-expr>,
      that limits the active combinations of the
      <index-name> values. For example,"
     
     [116:17] section 7.5.4.2.3, insert "that statement's " before
      "<mask-expr>"
     
     [116:18]  replace "with mask control by any control mask"  by "masked 
     by any control mask from outer nested WHERE constructs (7.5.3.2)"
     
     [116:19-20]  replace "with masked control by the control mask" with 
     "masked by the control mask in effect for the 
     where-assignment-statement"
     
     [118:11]  change "nonzero diagonal" to "nonzero off-diagonal"
     
     [118:19]  replace with "A many-to-one assignment is more than one 
     assignment to the same subobject" 
     
     [119:11]  from defect item 194
     insert "and possibly FORMAT <<and DATA statements>>" between 
     "constructs" and "that", where << >> is obsolescent font.
     
     [132:17]  change "9.1.3" to "9.5.1"
     
     [139:37]  after "default character." insert "When a record contains 
     any nondefault characters, the appropriate value for the RECL= 
     specifier is processor dependent."
     
     [143:32+]  Insert this introductory sentence
     "The FMT= specifier supplies a format specification or specifies list 
     directed formatting, for a formatted input/output statement."
     
     [146:13]  change "an assumed" to "a whole assumed"
     
     [146:14] (I/O implied do), insert to read "a nonpointer named .."
     
     [166:17]  add the missing "." after "yyy" and delete the "." after 
     "<exp>";
     put blanks around the dot, and the same for the "." at [167:9]
     
     [184:7-9]
     page 184, line 7 Insert at the beginning "Normal" and change 
     "Execution" to "execution";
     page 184, line 8, add at the end "Execution may also be terminated if 
     certain error 
     conditions occur."
     
     [184:29]  change to read "the object shall have the SAVE attribute."
     object is of a type" to "If a component is of a type".
     
     [187:17]  delete "objects having"
     
     [187:19+]  add as a new note
             "In the example
                BLOCK DATA INIT
                  REAL A, B, C, D, E, F
                  COMMON /BLOCK1/ A, B, C, D
                  DATA A /1.2/, C /2.3/
                  COMMON /BLOCK2/ E, F
                  DATA F /6.5/
                END BLOCK DATA INIT
             common blocks BLOCK1 and BLOCK2 both have objects that
             are being initialized in a single block data program unit.
             B, D and E are not initialized but need to be specified
             as part of the common blocks."
     
     [189:12]  after "expression", insert "(7.1.3)"
     
     [191:20]  add at the end of the line "or is an entry in a procedure 
     with the ELEMENTAL prefix-spec"
     
     [196:10]  delete this line
     
     [196:42]  change "operation and a" to "operation. A"
     
     [197:14]  replace the constraint with
     "Neither a procedure with the prefix-spec ELEMENTAL nor an entry in 
     such a procedure shall be used as an actual argument."
     
     [198:16]  change "Arguments" to "Actual arguments"
     
     [200:5]  change [200:5] delete "can", to read:  "a processor checks.." 
      
     
     [200:19]  add "Because an INTENT(OUT) variable is considered undefined 
     on entry to the procedure, any default initialization specified for 
     its type will be applied."
     
     [200:24-27]  moved to [199:26], so that they appear with  the rest  of 
      the  text  that  deals  with restrictions on passing scalars to 
     scalars.
     
     [200:32]  change "Arguments" to "Actual arguments"
     
     [200:37-39]  replace the first part of the sentence, up to but not 
     including 'except', with "If the interface of the dummy procedure is 
     explicit, the characteristics listed in 12.2 must be the same for the 
     associated actual procedure and the corresponding dummy procedure,"
     
     [200:39]  at the end of the sentence add "and an elemental intrinsic 
     actual procedure may be associated with a dummy procedure that is not 
     elemental"
     
     [200:45]  change "Arguments" to "Actual arguments"
     
     [204:31]  change "function reference" to "<function-reference>"
     
     [206:10]  replace "interface" with "characteristics", and change 12.3 
     to 12.2
     
     [206:35-36]  change to "If the <prefix-spec> PURE or ELEMENTAL is 
     present the function ..."
     
     [207:7]  delete "! The characteristics  ...   C_SUM"
     
     [208:20-21]  change "..specification statement" to "..specification or 
     type-declaration statement".
     
     [210:25]  delete "data object" from end of line
     
     [210:39]  change "has no side effects" to "shall have no side 
     effects";
     make the first sentence (from the second) "A pure procedure" followed 
     by the list;
     make the second sentence the former first sentence as modified
     
     [210:41]  on next page add a new list item (3) and renumber
           (3)  is an entry in a pure or elemental procedure
     
     [211:13]  change "alternate return specifiers" to "alternate return 
     indicators"
     
     [211:24-25]  replace the last sentence "The prefix-spec...interface" 
     with
     "The interface shall specify that the procedure is either pure or 
     elemental."
     
     [212:37]  add new sentence
     "In pure subroutines, side effects to dummy  arguments with the 
     POINTER attribute are also permitted."
     
     [213:12]  add note (but not in same box as following note)
     "For intrinsic functions, a similar rule applies.  See 13.3."
     
     [213:27]  copy the sentence from 213:11-13 " For a non-intrinsic ...   
     specification expression." to the end of 213:27 and replace "function" 
     with "subroutine" in the copied text.
     
     [213:30]  add as a note:
     "The restriction that actual arguments associated with dummy arguments 
     used in specification expressions shall be scalar allows elemental 
     procedures to have internal arrays, etc., whose size depends on dummy 
     arguments.  However, for any particular instance of an elemental 
     procedure reference, all of the internal arrays must be the same size. 
      This restriction was primarily added to facilitate optimization." 
     
     [223:22,23,24,25]  Replace each of these lines with two lines 
     identical to 224:4-5 or 224:6-7 except for the intrinsic function name 
     and description.
     
     [231:4]  delete the phrase, "It may be scalar or array valued."
     
     [244:36]  delete the phrase, "It may be scalar or array valued."
     
     [250:38,253:20,257:26,265:30]      Make identical to 249:33 or 253:20 
     except for the intrinsic function name and the section number.
     
     [250:44,253:26,257:35,265:36]      Remove "(optional)".
     
     [257:22]  add "The dummy argument A has no INTENT attribute".
     
     [257:21-22]  delete the phrase, "It may be scalar or array valued."
     
     [273:43-45]  change to "If a reference to the intrinsic function NULL 
     appears as an actual ..."
     
     [274:29] and [274:35]  change "interface block" to "generic interface"
     
     [275:33-35]  delete item (5) entirely
     
     [276:27]  change "its host" to "the host of the procedure or interface 
     block".
     
     [276:33]  change "to it." to "to the procedure."
     
     [276:45]  change "in the scoping unit of a statement" to "in the 
     scoping unit that contains a statement"
     
     [277:15-17]  move [277:15-17] to [276:43+]
     
     [279:2]  put "or  defined" in obsolescent font
     
     [281:37]  change to "The target of the  pointer  is  deallocated  
     other  than  through  the pointer" 
     
     [285:14-19]  in [285:14] and [285:18] change "masked array assignment" 
     to "masked array assignment or FORALL assignment"
     
     [289:31+]  add a definition for "assumed-shape array"; use the text in 
     [54:31-32]
     
     [291:42]  change "(12.7)" to "(2.4.5, 7.5, 12.7)"
     
     [299:8]  change "DO control variables" to "DO variables"; also, in the 
     text of item (1) change "do-variable" to "DO variable", and change the 
     title of B.1.1 from "DO variables" to "DO-Variables"
     
     [299:27]  change "implementing  each of the deleted features" to 
     "implementing any of the deleted features"
     
     [299:34-35]  change "a named" to "a nonpointer named"
     

