From 41e647a3f54afbb527e9457c0a41b8c9a5ed70f8 Mon Sep 17 00:00:00 2001 From: Alberto Sartori Date: Tue, 28 Jun 2022 18:10:30 +0200 Subject: add parenthesis to emphasize the order of evaluation --- src/buildtool/execution_api/local/local_action.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/buildtool/execution_api/local/local_action.cpp') diff --git a/src/buildtool/execution_api/local/local_action.cpp b/src/buildtool/execution_api/local/local_action.cpp index 93a00c0d..74f90258 100644 --- a/src/buildtool/execution_api/local/local_action.cpp +++ b/src/buildtool/execution_api/local/local_action.cpp @@ -209,7 +209,7 @@ auto LocalAction::CollectOutputFile(std::filesystem::path const& exec_path, const noexcept -> std::optional { auto file_path = exec_path / local_path; auto type = FileSystemManager::Type(file_path); - if (not type or not IsFileObject(*type)) { + if ((not type) or (not IsFileObject(*type))) { Logger::Log(LogLevel::Error, "expected file at {}", local_path); return std::nullopt; } @@ -232,7 +232,7 @@ auto LocalAction::CollectOutputDir(std::filesystem::path const& exec_path, -> std::optional { auto dir_path = exec_path / local_path; auto type = FileSystemManager::Type(dir_path); - if (not type or not IsTreeObject(*type)) { + if ((not type) or (not IsTreeObject(*type))) { Logger::Log(LogLevel::Error, "expected directory at {}", local_path); return std::nullopt; } -- cgit v1.2.3