From Jason Turner

[depr.fs.path.factory]

Diff to HTML by rtfpessoa

Files changed (1) hide show
  1. tmp/tmpsl01n6z6/{from.md → to.md} +13 -9
tmp/tmpsl01n6z6/{from.md → to.md} RENAMED
@@ -1,27 +1,31 @@
1
- ## Deprecated filesystem path factory functions <a id="depr.fs.path.factory">[[depr.fs.path.factory]]</a>
 
 
2
 
3
  ``` cpp
4
  template<class Source>
5
  path u8path(const Source& source);
6
  template<class InputIterator>
7
  path u8path(InputIterator first, InputIterator last);
8
  ```
9
 
10
- *Requires:* The `source` and \[`first`, `last`) sequences are UTF-8
11
- encoded. The value type of `Source` and `InputIterator` is `char` or
12
- `char8_t`. `Source` meets the requirements specified in [[fs.path.req]].
 
 
13
 
14
  *Returns:*
15
 
16
- - If `value_type` is `char` and the current native narrow
17
  encoding [[fs.path.type.cvt]] is UTF-8, return `path(source)` or
18
  `path(first, last)`; otherwise,
19
- - if `value_type` is `wchar_t` and the native wide encoding is UTF-16,
20
- or if `value_type` is `char16_t` or `char32_t`, convert `source` or
21
- \[`first`, `last`) to a temporary, `tmp`, of type `string_type` and
22
- return `path(tmp)`; otherwise,
23
  - convert `source` or \[`first`, `last`) to a temporary, `tmp`, of type
24
  `u32string` and return `path(tmp)`.
25
 
26
  *Remarks:* Argument format conversion [[fs.path.fmt.cvt]] applies to the
27
  arguments for these functions. How Unicode encoding conversions are
 
1
+ ### Deprecated filesystem path factory functions <a id="depr.fs.path.factory">[[depr.fs.path.factory]]</a>
2
+
3
+ The header `<filesystem>` has the following additions:
4
 
5
  ``` cpp
6
  template<class Source>
7
  path u8path(const Source& source);
8
  template<class InputIterator>
9
  path u8path(InputIterator first, InputIterator last);
10
  ```
11
 
12
+ *Mandates:* The value type of `Source` and `InputIterator` is `char` or
13
+ `char8_t`.
14
+
15
+ *Preconditions:* The `source` and \[`first`, `last`) sequences are UTF-8
16
+ encoded. `Source` meets the requirements specified in [[fs.path.req]].
17
 
18
  *Returns:*
19
 
20
+ - If `path::value_type` is `char` and the current native narrow
21
  encoding [[fs.path.type.cvt]] is UTF-8, return `path(source)` or
22
  `path(first, last)`; otherwise,
23
+ - if `path::value_type` is `wchar_t` and the native wide encoding is
24
+ UTF-16, or if `path::value_type` is `char16_t` or `char32_t`, convert
25
+ `source` or \[`first`, `last`) to a temporary, `tmp`, of type
26
+ `path::string_type` and return `path(tmp)`; otherwise,
27
  - convert `source` or \[`first`, `last`) to a temporary, `tmp`, of type
28
  `u32string` and return `path(tmp)`.
29
 
30
  *Remarks:* Argument format conversion [[fs.path.fmt.cvt]] applies to the
31
  arguments for these functions. How Unicode encoding conversions are