-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
C# out param is not reported as an error in visual studio if a local function is called. #69775
Comments
This issue was also reported in #70391 (comment) and @SirCxyrtyx offered some details on investigation there. |
Bug appears to have been introduced in 0ffa3fa. That same commit also introduced the PrimaryConstructors_15 flow analysis test, which seems to be quite flawed?
For this code:
It asserts that |
Assigned to @AlekseyTs as it looks like this changed due to primary constructor work |
…presence of local functions. Fixes dotnet#69775.
…presence of local functions. (dotnet#70563) Fixes dotnet#69775.
This issue has been moved from a ticket on Developer Community.
[severity:It's more difficult to complete my work]
I have attached a minimum reproducible project.
Notice the out method called 'bug' can compile even though the out parameter is not set.
The whole function:
OutBug.zip
Original Comments
Feedback Bot on 8/20/2023, 06:54 PM:
(private comment, text removed)
Original Solutions
(no solutions)
The text was updated successfully, but these errors were encountered: