Non-inout indirect types not supported in closure-specialization optimization

The closure-specialization optimization currently does not support non-inout indirect arguments. However, I could not find any explanation as to why they aren't (other than saying that it's a temporary limitation).

So, why are non-inout indirect types not supported in the closure-specialization optimization as of today?

There shouldn't be any fundamental reason. It may not have been a priority because the "opaque values" change that would push address lowering for indirect types to late in the pipeline has been coming "real soon now" for a while, but it would still be valuable to implement in the mean time.

1 Like

Would inout indirect types not have been affected by this change?