tmp/tmpgw27g60s/{from.md → to.md}
RENAMED
|
@@ -22,35 +22,42 @@ argument determined from `mode & ~ios_base::ate` as indicated in
|
|
| 22 |
[[filebuf.open.modes]]. If `mode` is not some combination of flags shown
|
| 23 |
in the table then the open fails.
|
| 24 |
|
| 25 |
**Table: File open modes** <a id="filebuf.open.modes">[filebuf.open.modes]</a>
|
| 26 |
|
| 27 |
-
| `binary` | `in` | `out` | `trunc` | `app` |
|
| 28 |
-
| -------- | ---- | ----- | ------- | ----- | --- | ------------------ |
|
| 29 |
-
| | | + | | | `"w"`
|
| 30 |
-
| | | + | | +
|
| 31 |
-
| | |
|
| 32 |
-
| | | + | + | | `"
|
| 33 |
-
| | +
|
| 34 |
-
| |
|
| 35 |
-
| | + |
|
| 36 |
-
| | + | + | |
|
| 37 |
-
| | + |
|
| 38 |
-
| +
|
| 39 |
-
| +
|
| 40 |
-
| +
|
| 41 |
-
| + | +
|
| 42 |
-
| + |
|
| 43 |
-
| + |
|
| 44 |
-
| + | +
|
| 45 |
-
| + | +
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 46 |
|
| 47 |
|
| 48 |
If the open operation succeeds and `ios_base::ate` is set in `mode`,
|
| 49 |
positions the file to the end (as if by calling
|
| 50 |
`fseek(file, 0, SEEK_END)`, where `file` is the pointer returned by
|
| 51 |
-
calling `fopen`).
|
| 52 |
|
| 53 |
If the repositioning operation fails, calls `close()` and returns a null
|
| 54 |
pointer to indicate failure.
|
| 55 |
|
| 56 |
*Returns:* `this` if successful, a null pointer otherwise.
|
|
@@ -77,9 +84,9 @@ or throws an exception, the function closes the file (as if by calling
|
|
| 77 |
`fclose(file)`). If any of the calls made by the function, including
|
| 78 |
`fclose`, fails, `close` fails by returning a null pointer. If one of
|
| 79 |
these calls throws an exception, the exception is caught and rethrown
|
| 80 |
after closing the file.
|
| 81 |
|
| 82 |
-
*Returns:* `this` on success, a null pointer otherwise.
|
| 83 |
-
|
| 84 |
*Ensures:* `is_open() == false`.
|
| 85 |
|
|
|
|
|
|
|
|
|
| 22 |
[[filebuf.open.modes]]. If `mode` is not some combination of flags shown
|
| 23 |
in the table then the open fails.
|
| 24 |
|
| 25 |
**Table: File open modes** <a id="filebuf.open.modes">[filebuf.open.modes]</a>
|
| 26 |
|
| 27 |
+
| `binary` | `in` | `out` | `trunc` | `app` | `noreplace` | `stdio` equivalent |
|
| 28 |
+
| -------- | ---- | ----- | ------- | ----- | ----------- | ------------------ |
|
| 29 |
+
| | | + | | | | `"w"` |
|
| 30 |
+
| | | + | | | + | `"wx"` |
|
| 31 |
+
| | | + | + | | | `"w"` |
|
| 32 |
+
| | | + | + | | + | `"wx"` |
|
| 33 |
+
| | | + | | + | | `"a"` |
|
| 34 |
+
| | | | | + | | `"a"` |
|
| 35 |
+
| | + | | | | | `"r"` |
|
| 36 |
+
| | + | + | | | | `"r+"` |
|
| 37 |
+
| | + | + | + | | | `"w+"` |
|
| 38 |
+
| | + | + | + | | + | `"w+x"` |
|
| 39 |
+
| | + | + | | + | | `"a+"` |
|
| 40 |
+
| | + | | | + | | `"a+"` |
|
| 41 |
+
| + | | + | | | | `"wb"` |
|
| 42 |
+
| + | | + | | | + | `"wbx"` |
|
| 43 |
+
| + | | + | + | | | `"wb"` |
|
| 44 |
+
| + | | + | + | | + | `"wbx"` |
|
| 45 |
+
| + | | + | | + | | `"ab"` |
|
| 46 |
+
| + | | | | + | | `"ab"` |
|
| 47 |
+
| + | + | | | | | `"rb"` |
|
| 48 |
+
| + | + | + | | | | `"r+b"` |
|
| 49 |
+
| + | + | + | + | | | `"w+b"` |
|
| 50 |
+
| + | + | + | + | | + | `"w+bx"` |
|
| 51 |
+
| + | + | + | | + | | `"a+b"` |
|
| 52 |
+
| + | + | | | + | | `"a+b"` |
|
| 53 |
|
| 54 |
|
| 55 |
If the open operation succeeds and `ios_base::ate` is set in `mode`,
|
| 56 |
positions the file to the end (as if by calling
|
| 57 |
`fseek(file, 0, SEEK_END)`, where `file` is the pointer returned by
|
| 58 |
+
calling `fopen`).[^38]
|
| 59 |
|
| 60 |
If the repositioning operation fails, calls `close()` and returns a null
|
| 61 |
pointer to indicate failure.
|
| 62 |
|
| 63 |
*Returns:* `this` if successful, a null pointer otherwise.
|
|
|
|
| 84 |
`fclose(file)`). If any of the calls made by the function, including
|
| 85 |
`fclose`, fails, `close` fails by returning a null pointer. If one of
|
| 86 |
these calls throws an exception, the exception is caught and rethrown
|
| 87 |
after closing the file.
|
| 88 |
|
|
|
|
|
|
|
| 89 |
*Ensures:* `is_open() == false`.
|
| 90 |
|
| 91 |
+
*Returns:* `this` on success, a null pointer otherwise.
|
| 92 |
+
|