[#bsl-vformat_to-0f]
= xref:bsl.adoc[bsl]::vformat&lowbar;to
:relfileprefix: ../
:mrdocs:

Format type&hyphen;erased `args` per `fmtStr` into `out` using locale `loc`&period;

== Synopsis

Declared in `&lt;bslfmt&lowbar;format&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
void
vformat&lowbar;to(
    xref:bsl/string.adoc[string]* out,
    std::locale const& loc,
    std::string&lowbar;view fmtStr,
    std::format&lowbar;args args);
----

== Description

Format the specified `args` according to the specification given by the specified `fmtStr` in the locale of the specified `loc`, and write the result of this operation into the string addressed by the specified `out` parameter&period; In the event of an error throw the exception `format&lowbar;error`&period; The behavior is undefined if `out` does not point to a valid `bsl&colon;&colon;string` object&period; Note that this overload is provided in addition to the overloads in the standard library&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *out*
| address of the string receiving formatted characters
| *loc*
| locale used for locale&hyphen;dependent formatting
| *fmtStr*
| format string
| *args*
| type&hyphen;erased format arguments
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
