Skip to content

Commit

Permalink
Move the path parameter in tmp::path constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
bugdea1er committed Jan 28, 2024
1 parent 444c277 commit b5df12e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/tmp/path.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class path {
/// Creates a unique temporary path using the given constructor function.
/// @param prefix the path between system temp
/// @param creator wrapped mktemp-like function that returns resulting path
explicit path(std::filesystem::path path) : underlying(path) {}
explicit path(std::filesystem::path path) : underlying(std::move(path)) {}

static std::filesystem::path make_parent(std::string_view prefix) {
const auto parent = std::filesystem::temp_directory_path() / prefix;
Expand Down

0 comments on commit b5df12e

Please sign in to comment.