J3/17-217r1 To: J3 From: Malcolm Cohen and Lorri Menard Subject: Generalized real and complex exposition Date: 2017 October 16 1. Introduction There are a number of problems with the exposition of generalized real and complex editing, especially in relation to the G0 edit descriptor. This paper proposes editorial changes to remove contradictions and hopefully improve clarity. One edit has a TECHNICAL EFFECT in that we describe two different semantics for one case, and it picks the one that I thought that we obviously meant. 2. Discussion (A) paragraph 1: The first paragraph is both internally contradictory and also contradicted by the rest of the subclause for output editing. The internal contradiction is that it specifies "The form and interpretation of the input field is the same as for Fw.d editing (13.7.2.3.2)." This is obviously problematic when d does not appear (e.g. the G0 edit descriptor) as it specifies the input form/interpretation is the same as the nonexistent "F0." edit descriptor. Yes, G0 is not allowed to be used for input editing, but it behooves us not to specify nonsense anyway. Perhaps more serious is that the subclause headings do not provide normative semantics, which means that this applis to all edit descriptors. Obviously we did not mean that, but we should say it properly. The "also" contradiction applies whether w is zero or not, and is twofold: (1) paragraph 2 specifies a different edit descriptor (not Fw.d) to be used when d==0; (2) paragraph 6 specifies a requirement that is impossible to satify for input editing, as the value of n is not determined in that case. Two changes will correct these problems: (1) Specify that the rest of the subclause only applies to output editing. (2) Reword to avoid specifying nonsense. (B) paragraph 2: This specifies a different form to be used for G0.0 (kPEw.0) from that of paragraph 3 (it specifies Gw.dEe with a processor-dependent value for e) and paragraph 4 (which specifies Fw.d). This seems to be an integration problem with the "E0.d" edit descriptor feature (F2008 did not allow w==0 for E), combined with some sloppy wording in F2008. In F2008, paragraph 2 was merely a small part of the general (complicated and wrong) specification of the rounding effects; it was extracted as a separate paragraph via interp. Clearly (?) this is not intended to apply when w==0, so an edit is provided to specify this. (C) paragraph 2: Executing this paragraph gives the reader a runtime null pointer crash for the G0 edit descriptor (because there is no "d"). The proposed fix for problem (B), that this paragraph does not apply when w==0, will fix this problem of exposition too. 3. Edits to 17-007r2 (N2137) [281:21] 13.7.5.2.2 Generalized real and complex editing, p1, After "of the input field" insert "for Gw.d and Gw.dEe editing", Append a new sentence: "The rest of this subclause applies only to output editing". {NB: w, d and e are hyperlinked italicised BNF terms. The editor is reminded to follow the existing style for spacing here.} The resulting paragraph becomes: "The form and interpretation of the input field for Gw.d and Gw.dEe editing is the same as for Fw.d editing (13.7.2.3.2). The rest of this subclause applies only to output editing." [281:22] Same subclause, p2, Before "d is zero" insert "w is nonzero and". {NB: Both d and w are italicised hyperlinked BNF terms. TECHNICAL CHANGE: This edit resolves a contradiction.} ===END===