<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;"><br id="lineBreakAtBeginningOfMessage"><div><br><blockquote type="cite"><div>Begin forwarded message:</div><br class="Apple-interchange-newline"><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;"><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif; color:rgba(0, 0, 0, 1.0);"><b>From: </b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;">Joseph Myers <josmyers@redhat.com><br></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;"><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif; color:rgba(0, 0, 0, 1.0);"><b>Subject: </b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;"><b>[SC22WG14.34201] FLT_EVAL_METHOD, double_t and Annex H</b><br></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;"><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif; color:rgba(0, 0, 0, 1.0);"><b>Date: </b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;">October 24, 2025 at 3:27:05 PM PDT<br></span></div><div style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px;"><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif; color:rgba(0, 0, 0, 1.0);"><b>To: </b></span><span style="font-family: -webkit-system-font, Helvetica Neue, Helvetica, sans-serif;">sc22wg14@open-std.org<br></span></div><br><div><div>Suppose FLT_EVAL_METHOD is 2 and long double has the same set of values as <br>double.<br><br>According to the main standard, FLT_EVAL_METHOD == 2 means that double_t <br>is defined as long double.<br><br>According to Annex H, FLT_EVAL_METHOD == 2 means "evaluate operations and <br>literals, whose semantic type comprises a set of values that is a strict <br>subset of the values of long double, to the range and precision of long <br>double; evaluate all other operations and literals to the range and <br>precision of the semantic type", and "If FLT_RADIX is 2 and <br>FLT_EVAL_METHOD (H.3) is nonnegative, then each of the types corresponding <br>to a standard or binary floating type is the type whose range and <br>precision are specified by FLT_EVAL_METHOD to be used for evaluating <br>operations and literals of that standard or binary floating type.".<br><br>Does that wording apply to double_t as well as to the other *_t defined in <br>Annex H?  If so, because the values of double aren't a *strict* subset of <br>those of double, "the type whose range and precision are specified by <br>FLT_EVAL_METHOD to be used for evaluating operations and literals of that <br>standard or binary floating type" would, in the case of double_t, be <br>double not long double, and that would indicate that double_t should be <br>defined as double (although float_t and long_double_t would be long <br>double).  Does that mean that Annex H does not permit FLT_EVAL_METHOD == 2 <br>when long double and double have the same set of values, because of that <br>contradiction in how to define double_t?<br><br>(Note: the "strict subset" in how FLT_EVAL_METHOD is defined in Annex H is <br>a change relative to TS 18661-3 which instead talked about "at most <br>the range and precision".  I don't know the reason for that change, which <br>affects the definition of the *_t types for types with the same set of <br>values as the type implied by FLT_EVAL_METHOD - for example, if <br>FLT_EVAL_METHOD is 2, it affects double_t if double has the same set of <br>values as long double, _Float64_t if _Float64 does, and so on.)<br><br>-- <br>Joseph S. Myers<br>josmyers@redhat.com</div></div></blockquote></div><br></body></html>