Template:cpp/locale/byname/constructor

{{member|{{small|std::{{{1}}}::}}{{{1}}}| {{dcl begin}} {{dcl|1= explicit {{{1}}}( const char* name, std::size_t refs = 0 ); }} {{dcl|since=c++11|1= explicit {{{1}}}( const std::string& name, std::size_t refs = 0 ); }} {{dcl end}}

Constructs a new {{tt|std::{{{1}}}}} facet for a locale with {{c|name}}.

{{c|refs}} is used for resource management: if {{c|1=refs == 0}}, the implementation destroys the facet, when the last {{lc|std::locale}} object holding it is destroyed. Otherwise, the object is not destroyed.

Parameters
}}