From 866f84b74c40025999e314188eca58902836d872 Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Sat, 2 Aug 2025 18:40:42 +0200 Subject: [PATCH] refactor: Rename local variable in macro to avoid clashes --- src/ccache/util/expected.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/ccache/util/expected.hpp b/src/ccache/util/expected.hpp index bb23c5ff..a99cd2a3 100644 --- a/src/ccache/util/expected.hpp +++ b/src/ccache/util/expected.hpp @@ -1,4 +1,4 @@ -// Copyright (C) 2021-2024 Joel Rosdahl and other contributors +// Copyright (C) 2021-2025 Joel Rosdahl and other contributors // // See doc/AUTHORS.adoc for a complete list of contributors. // @@ -52,9 +52,9 @@ void throw_on_error(const T& value, std::string_view prefix); #define TRY(x_) \ do { \ - const auto result = x_; \ - if (!result) { \ - return tl::unexpected(result.error()); \ + const auto result_ = x_; \ + if (!result_) { \ + return tl::unexpected(result_.error()); \ } \ } while (false) -- 2.47.2