diff options
Diffstat (limited to 'src/buildtool/main')
-rw-r--r-- | src/buildtool/main/build_utils.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/buildtool/main/build_utils.cpp b/src/buildtool/main/build_utils.cpp index 684d2dd1..17b26d80 100644 --- a/src/buildtool/main/build_utils.cpp +++ b/src/buildtool/main/build_utils.cpp @@ -92,7 +92,8 @@ auto CreateTargetCacheWriterMap( // get the TaretCacheKey corresponding to this Id TargetCacheKey tc_key{key}; // check if entry actually needs storing - if (not cache_targets.contains(tc_key)) { + auto const tc_key_it = cache_targets.find(tc_key); + if (tc_key_it == cache_targets.end()) { if (tc.Read(tc_key)) { // entry already in target-cache, so nothing to be done (*setter)(nullptr); @@ -104,9 +105,8 @@ auto CreateTargetCacheWriterMap( true); return; } - auto const& target = cache_targets.at(tc_key); auto entry = TargetCacheEntry::FromTarget( - apis->remote->GetHashType(), target, extra_infos); + apis->remote->GetHashType(), tc_key_it->second, extra_infos); if (not entry) { (*logger)( fmt::format("Failed creating target cache entry for key {}", |