-
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
IntelliSense cannot detect IAsyncEnumerable's yield return type when that parameter is used #68027
Comments
Attempt to "navigate" around the issue by declaring a variable does not work as well (note that However this issue does not happen if |
Hi any update on this? This is quite annoying to work with because I keep losing code suggestion. Thanks. |
@datvm There is no update on this. We would take a community contribution to fix this though, if you were interested :) |
@CyrusNajmabadi thanks. I hope someone can take a look at this. Unfortunately I am quite unfamiliar with Roslyn so I cannot really help :( |
Moving to compiler. We call into their apis for semantic information. |
Fix was merged into 17.13p2. Thanks for reporting this issue @datvm ! |
That issue is not related. The issue here, which was fixed, relates to a lambda in a |
Version Used: 4.5.2-3.23171.7 (d17f741)
Steps to Reproduce:
Put in the following code (in this example it's in the top-level
Program.cs
):The code above compiles but at the
// Happen here
line, any attempt to accesss
results ins
being unknown?
even though without it, the compiler and IntelliSense correctly detects
asstring
.Diagnostic Id: N/A
Expected Behavior:
s
should maintain its type asstring
while typing.Actual Behavior:
Whenever there is an attempt to access
s
, it becomes?
. This happens to both Visual Studio and VS Code (latest version). If you put in valid code without IntelliSense, it still compiles, for example:Correct behavior when
s
is not being typed:In both VS and VS Code,
s
becomes unknown when any attempt to access it is made:The text was updated successfully, but these errors were encountered: