From 216aa149974a179d49094e53f553741e2c385920 Mon Sep 17 00:00:00 2001 From: Brad King Date: Wed, 5 Jan 2022 12:35:49 -0500 Subject: cmGeneratorTarget: Return early from ExpandLinkItems with no items --- Source/cmGeneratorTarget.cxx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Source/cmGeneratorTarget.cxx b/Source/cmGeneratorTarget.cxx index d1c5819..f8fa593 100644 --- a/Source/cmGeneratorTarget.cxx +++ b/Source/cmGeneratorTarget.cxx @@ -6666,6 +6666,9 @@ void cmGeneratorTarget::ExpandLinkItems(std::string const& prop, LinkInterfaceFor interfaceFor, cmLinkInterface& iface) const { + if (entries.empty()) { + return; + } // Keep this logic in sync with ComputeLinkImplementationLibraries. cmGeneratorExpressionDAGChecker dagChecker(this, prop, nullptr, nullptr); // The $ expression may be in a link interface to specify -- cgit v0.12