• Brad King's avatar
    Genex: Fix value lifetimes in nested TARGET_PROPERTY evaluation · 5a1af142
    Brad King authored
    For special properties like `INCLUDE_DIRECTORIES`, the pointer returned
    by `cmTarget::GetProperty` is only valid until the next time the same
    special property is queried on *any* target.  When evaluating a nested
    `TARGET_PROPERTY` generator expression we may look up such a property
    more than once on different targets.  Fix `TargetPropertyNode::Evaluate`
    to store the lookup result in locally owned memory earlier.
    
    Fixes: #19286
    5a1af142