Skip to content

Commit

Permalink
Use / as path separators on Windows.
Browse files Browse the repository at this point in the history
  • Loading branch information
dillof committed May 2, 2024
1 parent 93ea874 commit af9e5b3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/File.cc
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ void File::create_output() const { // NOLINT(misc-no-recursion)
throw Exception("can't create output '%s'", build_filename.c_str());
}

stream << "# This file is automatically created by fast-ninja from " << source_filename.string() << std::endl;
stream << "# This file is automatically created by fast-ninja from " << source_filename.generic_string() << std::endl;
stream << "# Do not edit." << std::endl << std::endl;

if (!bindings.empty()) {
Expand All @@ -169,7 +169,7 @@ void File::create_output() const { // NOLINT(misc-no-recursion)
if (!subninjas.empty()) {
stream << std::endl;
for (auto& subninja : subninjas) {
stream << "subninja " << replace_extension(subninja, "ninja").string() << std::endl;
stream << "subninja " << replace_extension(subninja, "ninja").generic_string() << std::endl;
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/Filename.cc
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,6 @@ std::filesystem::path Filename::full_name() const {
}

std::ostream& operator<<(std::ostream& stream, const Filename& file_name) {
stream << file_name.full_name().string();
stream << file_name.full_name().generic_string();
return stream;
}

0 comments on commit af9e5b3

Please sign in to comment.