Skip to content

Commit eae8525

Browse files
committed
improve readability by adopting structured binding
1 parent 50faf51 commit eae8525

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

llvm/lib/CGData/StableFunctionMap.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,10 +146,11 @@ StableFunctionMap::at(HashFuncsMapType::key_type FunctionHash) const {
146146
void StableFunctionMap::deserializeLazyLoadingEntry(
147147
HashFuncsMapType::iterator It) {
148148
assert(isLazilyLoaded() && "Cannot deserialize non-lazily-loaded map");
149-
std::call_once(It->second.LazyLoadFlag, [this, It]() {
150-
for (auto Offset : It->second.Offsets)
149+
auto& [Hash, Storage] = *It;
150+
std::call_once(Storage.LazyLoadFlag, [this, HashArg = Hash, &StorageArg = Storage]() {
151+
for (auto Offset : StorageArg.Offsets)
151152
StableFunctionMapRecord::deserializeEntry(
152-
reinterpret_cast<const unsigned char *>(Offset), It->first, this,
153+
reinterpret_cast<const unsigned char *>(Offset), HashArg, this,
153154
ReadStableFunctionMapNames);
154155
});
155156
}

0 commit comments

Comments
 (0)