You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Expected:
Escape analysis should report errors for the conversions from interpolated string to CustomHandler since a reference to the local is potentially returned to the calling method.
Actual:
No errors.
The text was updated successfully, but these errors were encountered:
In this bit, it seems like we weren't precisely correct in our assumptions on how the calls within interpolated string conversions could be formed. An unscoped in-parameter could come in here which we don't handle properly:
I think we could avoid entirely making assumptions about the shape of the call here, and instead just pass it through the appropriate general purpose helper for calls (GetInvocationArgumentsForEscape or GetInvocationArgumentsForEscapeWithUpdatedRules in #62886). Another layer may be synthesizing the call within some limited set of constraints, but it doesn't matter to the escape analysis layer.
This is no longer a bug because the in here is RTSE of return only so it can't be captured. A very related scenario is if a ref struct is passed by value that is tracked by our current code. There is no test for that scenario though. This bug will now track updating the existign test for in and adding a new test for passing a ref struct by value
Expected:
Escape analysis should report errors for the conversions from interpolated string to
CustomHandler
since a reference to the local is potentially returned to the calling method.Actual:
No errors.
The text was updated successfully, but these errors were encountered: