From e7d9377534e0512b0d13e45e8cf97f8107c9f024 Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Sun, 2 Jun 2024 13:02:17 +0200 Subject: [PATCH] refactor: Convert ArgsInfo::output_dia to fs::path --- src/ccache/ArgsInfo.hpp | 2 +- src/ccache/argprocessing.cpp | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/ccache/ArgsInfo.hpp b/src/ccache/ArgsInfo.hpp index 6ccd55de..84d2635c 100644 --- a/src/ccache/ArgsInfo.hpp +++ b/src/ccache/ArgsInfo.hpp @@ -60,7 +60,7 @@ struct ArgsInfo std::filesystem::path output_ci; // Diagnostic generation information (Clang). Contains pathname if not empty. - std::string output_dia; + std::filesystem::path output_dia; // Split dwarf information (GCC 4.8 and up). Contains pathname if not empty. std::string output_dwo; diff --git a/src/ccache/argprocessing.cpp b/src/ccache/argprocessing.cpp index 49428349..9e9673cd 100644 --- a/src/ccache/argprocessing.cpp +++ b/src/ccache/argprocessing.cpp @@ -1010,8 +1010,7 @@ process_option_arg(const Context& ctx, return Statistic::bad_compiler_arguments; } args_info.generating_diagnostics = true; - args_info.output_dia = - util::pstr(core::make_relative_path(ctx, args[i + 1])); + args_info.output_dia = core::make_relative_path(ctx, args[i + 1]); i++; return Statistic::none; } -- 2.47.2