File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -64,7 +64,7 @@ The example below demonstrates a usage of a `tmp::file` object to validate a req
6464
6565auto func (std::string_view content) {
6666 auto tmpfile = tmp::file();
67- tmpfile << contents << std::flush;
67+ tmpfile << content << std::flush;
6868 if (validate(tmpfile)) {
6969 // Unarchive the file to the persistent storage
7070 archive::unzip(tmpfile, storage);
Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ extern "C++" int get_native_handle(std::FILE* file) noexcept;
3535// / Upon creation, a tmp::file object generates a unique temporary file,
3636// / opening it for reading and writing in binary format
3737// /
38- // / The temporary file is deleted of when either of the following happens:
38+ // / The temporary file is deleted when either of the following happens:
3939// / - the tmp::file object is destroyed
4040// / - the tmp::file object is assigned another file using operator=
4141// /
@@ -51,7 +51,7 @@ extern "C++" int get_native_handle(std::FILE* file) noexcept;
5151// /
5252// / auto func(std::string_view content) {
5353// / auto tmpfile = tmp::file();
54- // / tmpfile << contents << std::flush;
54+ // / tmpfile << content << std::flush;
5555// / if (validate(tmpfile)) {
5656// / // Unarchive the file to the persistent storage
5757// / archive::unzip(tmpfile, storage);
You can’t perform that action at this time.
0 commit comments