cmComputeLinkInformation: Simplify recording OBJECT libraries as link items

Simplify commit 2c7acd34e2 (cmComputeLinkInformation: add `OBJECT`
libraries as link items, 2023-07-24, v3.28.0-rc1~279^2) using the
existing local variables.
This commit is contained in:
Brad King
2023-11-14 11:17:52 -05:00
parent baec1dac9b
commit 377b78aef9

View File

@@ -1162,7 +1162,7 @@ void cmComputeLinkInformation::AddItem(LinkEntry const& entry)
this->AddItem(BT<std::string>(libName, item.Backtrace));
}
} else if (tgt->GetType() == cmStateEnums::OBJECT_LIBRARY) {
this->Items.emplace_back(entry.Item, ItemIsPath::No, entry.Target);
this->Items.emplace_back(item, ItemIsPath::No, tgt);
} else if (this->GlobalGenerator->IsXcode() &&
!tgt->GetImportedXcFrameworkPath(config).empty()) {
this->Items.emplace_back(