dotnet/roslyn

Missing test case for conditional access in `CheckValEscape`

Open

#57,653 opened on Nov 9, 2021

 (0 comments) (0 reactions) (0 assignees)C# (4,257 forks)batch import
Area-CompilersBughelp wanted

Repository metrics

Stars
 (20,414 stars)
PR merge metrics
 (Avg merge 6d 17h) (256 merged PRs in 30d)

Description

https://github.com/dotnet/roslyn/pull/57050#discussion_r726383228 adds a test case that hits a conditional access receiver in Binder.GetValEscape. This suggests that CheckValEscape should also be able to see this node in an error scenario, like GetValEscape, but we don't have a test case covering this so we haven't added it to the switch there. We should investigate to see if a test case can be created where that node is hit in CheckValEscape as well.

Contributor guide