From Jason Turner

[format.range.fmtset]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmp9ad6bdsz/{from.md → to.md} +51 -0
tmp/tmp9ad6bdsz/{from.md → to.md} RENAMED
@@ -0,0 +1,51 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #### Specialization of *`range-default-formatter`* for sets <a id="format.range.fmtset">[[format.range.fmtset]]</a>
2
+
3
+ ``` cpp
4
+ namespace std {
5
+ template<ranges::input_range R, class charT>
6
+ struct range-default-formatter<range_format::set, R, charT> {
7
+ private:
8
+ using maybe-const-set = fmt-maybe-const<R, charT>; // exposition only
9
+ range_formatter<remove_cvref_t<ranges::range_reference_t<maybe-const-set>>,
10
+ charT> underlying_; // exposition only
11
+
12
+ public:
13
+ constexpr range-default-formatter();
14
+
15
+ template<class ParseContext>
16
+ constexpr typename ParseContext::iterator
17
+ parse(ParseContext& ctx);
18
+
19
+ template<class FormatContext>
20
+ typename FormatContext::iterator
21
+ format(maybe-const-set& r, FormatContext& ctx) const;
22
+ };
23
+ }
24
+ ```
25
+
26
+ ``` cpp
27
+ constexpr range-default-formatter();
28
+ ```
29
+
30
+ *Effects:* Equivalent to:
31
+
32
+ ``` cpp
33
+ underlying_.set_brackets(STATICALLY-WIDEN<charT>("{"), STATICALLY-WIDEN<charT>("}"));
34
+ ```
35
+
36
+ ``` cpp
37
+ template<class ParseContext>
38
+ constexpr typename ParseContext::iterator
39
+ parse(ParseContext& ctx);
40
+ ```
41
+
42
+ *Effects:* Equivalent to: `return `*`underlying_`*`.parse(ctx);`
43
+
44
+ ``` cpp
45
+ template<class FormatContext>
46
+ typename FormatContext::iterator
47
+ format(maybe-const-set& r, FormatContext& ctx) const;
48
+ ```
49
+
50
+ *Effects:* Equivalent to: `return `*`underlying_`*`.format(r, ctx);`
51
+