<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Feedback from the C committee urged the following changes to our draft TS Part 1:<div><br></div><div><ul><li>Allow freestanding implementations to conform.&nbsp;</li><li>Guard library interfaces with a WANT macro.</li><li>In Table 1 add a column (or two) with forward references (clause numbers) for the C operations in the row. (The current order in the table seemed ok.)</li><li>Distinguish text in (and proposed for) the C standard from other text in the TS, by indentation (or some other means).</li><li>Find a better way to specify function calls that are affected by constant rounding modes. One approach is to list potentially affected functions (in a table) and have their invocations be affected if macro replacement has not been suppressed. This approach seemed promising after review by interested committee members.</li></ul><div>I've done the last four in my copy of our working draft, which I'll post for review soon.&nbsp;</div><div><br></div><div>A key issue for the first one is avoiding the requirement for freestanding implementations to support &lt;stdlib.h&gt; and &lt;stdio.h&gt;. Below is a draft specification for a new header that provides the character sequence conversion functionality required by IEEE 754. Please look it over and send comments. I'd be particularly interested in hearing from Joel, who first asked for this facility.</div></div><div><br></div><div>-Jim</div><div><br></div><div>=======================</div><div><br></div><div>n&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;Floating-point&nbsp;string conversions &lt;floatstr.h&gt;<br>&nbsp;<br>The&nbsp;header&nbsp;&lt;floatstr.h&gt;&nbsp;defines&nbsp;one type and five functions for converting between floating types and decimal&nbsp;character sequences.<br>&nbsp;<br>The type&nbsp;declared is&nbsp;size_t&nbsp;(described in&nbsp;7.19).<br>&nbsp;<br>n.1&nbsp; &nbsp; &nbsp; &nbsp;The&nbsp;strfromd and strfromld functions<br>&nbsp;<br>Synopsis<br>&nbsp;<br>#include &lt;floatstr.h&gt;<br>int strfromd(char * restrict s, size_t&nbsp;n, const char * restrict format, double x);<br>int strfromld(char * restrict s, size_t&nbsp;n, const char * restrict format, long double x);<br>&nbsp;<br>Descripton<br>&nbsp;<br>The&nbsp;strfromd&nbsp;and&nbsp;strfromld&nbsp;functions are defined by&nbsp;snprintf(s, n, format, x)&nbsp;(7.21.6.5).<br>&nbsp;<br>NOTE&nbsp;&nbsp;If the conversion specifier (in the string&nbsp;pointed to by&nbsp;format) for&nbsp;x&nbsp;is not for type&nbsp;double&nbsp;or&nbsp;long double, the&nbsp;behavior of&nbsp;strfromd&nbsp;or&nbsp;strfromld,&nbsp;respectively, is undefined.<br>&nbsp;<br>Returns<br>&nbsp;<br>The&nbsp;strfromd&nbsp;and&nbsp;strfromld&nbsp;functons return the values returned by&nbsp;snprintf(s, n, format, x)&nbsp;(7.21.6.5).<br>&nbsp;<br>n.2&nbsp; &nbsp; &nbsp; &nbsp;The strtod, strtof, and strtold functions<br>&nbsp;<br>Synopsis<br>&nbsp;<br>#include&nbsp;&lt;floatstr.h&gt;
<br>double&nbsp;strtod(const char * restrict nptr, char ** restrict endptr);<br>float&nbsp;strtof(const char * restrict nptr,&nbsp;char ** restrict endptr);<br>long&nbsp;double strtold(const char * restrict nptr, char ** restrict endptr);<br>.&nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;<br>These&nbsp;functions are specified in 7.22.1.3.</div></body></html>