From 3a771602f8ee6c7940208d447463061aa9b6af8c Mon Sep 17 00:00:00 2001 From: Maksim Denisov Date: Thu, 29 Aug 2024 11:55:07 +0200 Subject: Return the IsTree flag from ArtifactDigest ...and replace obvious redundant conversions to bazel_re::Digest, which were done to ensure that the digest represents a tree. --- src/buildtool/execution_engine/executor/executor.hpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/buildtool/execution_engine/executor/executor.hpp') diff --git a/src/buildtool/execution_engine/executor/executor.hpp b/src/buildtool/execution_engine/executor/executor.hpp index 26e415b1..ad2fefea 100644 --- a/src/buildtool/execution_engine/executor/executor.hpp +++ b/src/buildtool/execution_engine/executor/executor.hpp @@ -351,8 +351,7 @@ class ExecutorImpl { Artifact::ObjectInfo const& info, std::string const& hash) noexcept -> bool { std::optional content; - if (NativeSupport::IsTree( - static_cast(info.digest).hash())) { + if (info.digest.IsTree()) { // if known tree is not available, recursively upload its content auto tree = ReadGitTree(repo, repo_config, hash); if (not tree) { -- cgit v1.2.3