dotnet/roslyn

VB Editor IntelliSense does not show Task's members in ContinueWith

Open

#8.482 geöffnet am 9. Feb. 2016

Auf GitHub ansehen
 (0 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)C# (4.257 Forks)batch import
Area-CompilersBughelp wanted

Repository-Metriken

Stars
 (20.414 Stars)
PR-Merge-Metriken
 (Durchschn. Merge 6T 17h) (256 gemergte PRs in 30 T)

Beschreibung

This item was filed by a customer. Please communicate and close the loop with your customer via the customer tab inside TFS.


Problem Description


Description: I have the following VB code:

 Public Class Form1 

 Private Sub OnTest() Handles Button1.Click 

 Dim t = Task.Factory.StartNew(Function() 5) 
 t.ContinueWith(Sub(ant) MsgBox(ant.Result)) 

 End Sub 

 End Class 

This code compiles perfectly, but there's one bug: as soon as I type MsgBox(ant., then IntelliSense treats ant as Object - and hence doesn't show me Task's members - only Object's one.

Repro Steps:Code

 Private Sub OnTest() Handles Button1.Click 

 Dim t = Task.Factory.StartNew(Function() 5) 
 t.ContinueWith(Sub(ant) MsgBox(ant.Result)) 

 End Sub 

Impact:IntelliSense treats "ant" variable as Object.

Contributor Guide