std::filesystem::rename From cppreference.com <cpp |filesystem Defined in header<filesystem> voidrename(conststd::filesystem::path&old_p, conststd::filesystem::path&new_p); (1)(since C++17) voidrename(conststd::filesystem::path&old_p, ...
重命名只是原子性的。在state_path.parent_path()而不是当前工作目录下创建output_file。- Botje ...