[#BloombergLP-bslalg-NumericFormatterUtil-toChars-0c] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslalg.adoc[bslalg]::xref:BloombergLP/bslalg/NumericFormatterUtil.adoc[NumericFormatterUtil]::toChars :relfileprefix: ../../../ :mrdocs: Format floating‐point `value` into `[first, last)]`. == Synopsis Declared in `<bslalg_numericformatterutil.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- static char* toChars( char* first, char* last, double value) noexcept; ---- == Description Write the specified floating point `value` into the character buffer starting at the specified `first` and ending at the specified `last`, `last` not included. Use the {Default Floating Point Format}. Return the address one past the last character written on success, or `0` on failure. The only reason for failure is when the range `[ first, last )]` is not large enough to contain the result. The behavior is undefined unless `first <= last`. Note that these functions do *not* null‐terminate the result. == Return Value pointer past the last character written, or null on failure == Parameters [cols="1,4"] |=== | Name| Description | *first* | beginning of the output character range | *last* | end of the output character range | *value* | floating‐point value to format |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#