diff options
Diffstat (limited to 'src/buildtool/common/artifact_digest.hpp')
-rw-r--r-- | src/buildtool/common/artifact_digest.hpp | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/src/buildtool/common/artifact_digest.hpp b/src/buildtool/common/artifact_digest.hpp index ebd01ceb..24097776 100644 --- a/src/buildtool/common/artifact_digest.hpp +++ b/src/buildtool/common/artifact_digest.hpp @@ -96,21 +96,6 @@ class ArtifactDigest final { } } - template <ObjectType kType> - [[nodiscard]] static auto CreateFromFile( - HashFunction hash_function, - std::filesystem::path const& path) noexcept - -> std::optional<ArtifactDigest> { - static constexpr bool kIsTree = IsTreeObject(kType); - auto const hash = kIsTree ? hash_function.HashTreeFile(path) - : hash_function.HashBlobFile(path); - if (hash) { - return ArtifactDigest{ - hash->first.HexString(), hash->second, kIsTree}; - } - return std::nullopt; - } - private: std::size_t size_{}; std::string hash_{}; |