Additional fixes for MacOS clang

Apparently they do not support the double reference capture, so we just
pass the pointer reference by value
This commit is contained in:
Seth Hillbrand 2024-07-25 16:08:55 +02:00
parent 1be2d7f8b7
commit 3f3505570a

View File

@ -88,7 +88,8 @@ void ZONES_CONTAINER::OnUserConfirmChange()
{
std::map<PCB_LAYER_ID, std::shared_ptr<SHAPE_POLY_SET>> filled_zone_to_restore;
zone->GetLayerSet().RunOnLayers(
[&]( PCB_LAYER_ID layer )
// Capture 'zone' by value and 'filled_zone_to_restore' by reference for MacOS clang
[&filled_zone_to_restore, zone]( PCB_LAYER_ID layer )
{
std::shared_ptr<SHAPE_POLY_SET> fill = zone->GetFilledPolysList( layer );
if( fill )
@ -135,4 +136,4 @@ bool ZONES_CONTAINER::FlushPriorityChange()
}
return priorityChanged;
}
}