tmp/tmpe33goxvn/{from.md → to.md}
RENAMED
|
@@ -1,13 +1,13 @@
|
|
| 1 |
-
####
|
| 2 |
|
| 3 |
``` cpp
|
| 4 |
basic_fstream();
|
| 5 |
```
|
| 6 |
|
| 7 |
-
*Effects:*
|
| 8 |
-
|
| 9 |
`sb` with `basic_filebuf<charT, traits>()`.
|
| 10 |
|
| 11 |
``` cpp
|
| 12 |
explicit basic_fstream(
|
| 13 |
const char* s,
|
|
@@ -15,12 +15,12 @@ explicit basic_fstream(
|
|
| 15 |
explicit basic_fstream(
|
| 16 |
const filesystem::path::value_type* s,
|
| 17 |
ios_base::openmode mode = ios_base::in | ios_base::out); // wide systems only; see [fstream.syn]
|
| 18 |
```
|
| 19 |
|
| 20 |
-
*Effects:*
|
| 21 |
-
|
| 22 |
`sb` with `basic_filebuf<charT, traits>()`. Then calls
|
| 23 |
`rdbuf()->open(s, mode)`. If that function returns a null pointer, calls
|
| 24 |
`setstate(failbit)`.
|
| 25 |
|
| 26 |
``` cpp
|
|
@@ -30,16 +30,16 @@ explicit basic_fstream(
|
|
| 30 |
explicit basic_fstream(
|
| 31 |
const filesystem::path& s,
|
| 32 |
ios_base::openmode mode = ios_base::in | ios_base::out);
|
| 33 |
```
|
| 34 |
|
| 35 |
-
*Effects:*
|
| 36 |
|
| 37 |
``` cpp
|
| 38 |
basic_fstream(basic_fstream&& rhs);
|
| 39 |
```
|
| 40 |
|
| 41 |
-
*Effects:* Move constructs
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
|
| 45 |
|
|
|
|
| 1 |
+
#### Constructors <a id="fstream.cons">[[fstream.cons]]</a>
|
| 2 |
|
| 3 |
``` cpp
|
| 4 |
basic_fstream();
|
| 5 |
```
|
| 6 |
|
| 7 |
+
*Effects:* Initializes the base class with
|
| 8 |
+
`basic_iostream<charT, traits>(addressof(sb))` [[iostream.cons]] and
|
| 9 |
`sb` with `basic_filebuf<charT, traits>()`.
|
| 10 |
|
| 11 |
``` cpp
|
| 12 |
explicit basic_fstream(
|
| 13 |
const char* s,
|
|
|
|
| 15 |
explicit basic_fstream(
|
| 16 |
const filesystem::path::value_type* s,
|
| 17 |
ios_base::openmode mode = ios_base::in | ios_base::out); // wide systems only; see [fstream.syn]
|
| 18 |
```
|
| 19 |
|
| 20 |
+
*Effects:* Initializes the base class with
|
| 21 |
+
`basic_iostream<charT, traits>(addressof(sb))` [[iostream.cons]] and
|
| 22 |
`sb` with `basic_filebuf<charT, traits>()`. Then calls
|
| 23 |
`rdbuf()->open(s, mode)`. If that function returns a null pointer, calls
|
| 24 |
`setstate(failbit)`.
|
| 25 |
|
| 26 |
``` cpp
|
|
|
|
| 30 |
explicit basic_fstream(
|
| 31 |
const filesystem::path& s,
|
| 32 |
ios_base::openmode mode = ios_base::in | ios_base::out);
|
| 33 |
```
|
| 34 |
|
| 35 |
+
*Effects:* Equivalent to: `basic_fstream(s.c_str(), mode)`.
|
| 36 |
|
| 37 |
``` cpp
|
| 38 |
basic_fstream(basic_fstream&& rhs);
|
| 39 |
```
|
| 40 |
|
| 41 |
+
*Effects:* Move constructs the base class, and the contained
|
| 42 |
+
`basic_filebuf`. Then calls
|
| 43 |
+
`basic_istream<charT, traits>::set_rdbuf(addressof(sb))` to install the
|
| 44 |
+
contained `basic_filebuf`.
|
| 45 |
|