This commit is contained in:
2025-10-25 03:02:53 +03:00
commit 043225d523
3416 changed files with 681196 additions and 0 deletions

44
cppdraft/locale/id.md Normal file
View File

@@ -0,0 +1,44 @@
[locale.id]
# 28 Text processing library [[text]](./#text)
## 28.3 Localization library [[localization]](localization#locale.id)
### 28.3.3 Locales [[locales]](locales#locale.id)
#### 28.3.3.1 Class locale [[locale]](locale#id)
#### 28.3.3.1.2 Types [[locale.types]](locale.types#locale.id)
#### 28.3.3.1.2.3 Class locale::id [locale.id]
[🔗](#lib:locale,id)
namespace std {class locale::id {public: id(); void operator=(const id&) = delete;
id(const id&) = delete; };}
[1](#1)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/text.tex#L840)
The class locale::id provides
identification of a locale facet interface,
used as an index for lookup and to encapsulate initialization[.](#1.sentence-1)
[2](#2)
[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/text.tex#L845)
[*Note [1](#note-1)*:
Because facets are used by iostreams,
potentially while static constructors are running,
their initialization cannot depend on programmed static initialization[.](#2.sentence-1)
One initialization strategy is for locale to initialize each facet's id member
the first time an instance of the facet is installed into a locale[.](#2.sentence-2)
This depends only on static storage being zero
before constructors run ([[basic.start.static]](basic.start.static "6.10.3.2Static initialization"))[.](#2.sentence-3)
— *end note*]