.NET Interactive combines the power of .NET with many other languages to create notebooks, REPLs, and embedded coding experiences. Share code, explore data, write, and learn across your apps in ways you couldn't before.
MIT License
2.8k
stars
371
forks
source link
C# - Autocompletion suggestion has immediate errors #3550
in "csharp - C# Script" the auto-completions suggestions are causing immediate errors.
For example, in the screenshots/code below, the variables are of type IPagedList<T> : IList<T>.
Auto-completion suggests Select<> as a method.
Using that, completing the expression, and filling in the type yields errors:
'IPagedList' does not contain a definition for 'Select' and no accessible extension method 'Select' accepting a first argument of type 'IPagedList' could be found (are you missing a using directive or an assembly reference?)
Except it should because System.Linq is part of the usings, and the simpler/type-inferred Select() method works just fine.
Or rather: why is Autocomplete suggesting something that wouldn't work?
Please complete the following:
Which version of .NET Interactive are you using? (In a notebook, run the #!about magic command. ):
Describe the bug
in "csharp - C# Script" the auto-completions suggestions are causing immediate errors. For example, in the screenshots/code below, the variables are of type
IPagedList<T> : IList<T>
.Auto-completion suggests![Screenshot 2024-05-10 at 8 58 21 PM](https://github.com/dotnet/interactive/assets/709928/d67f24a1-8007-4026-ad94-af46ff592f7a)
Select<>
as a method.Using that, completing the expression, and filling in the type yields errors:
Except it should because
System.Linq
is part of the usings, and the simpler/type-inferredSelect()
method works just fine.Or rather: why is Autocomplete suggesting something that wouldn't work?
Please complete the following:
Which version of .NET Interactive are you using? (In a notebook, run the
#!about
magic command. ):Screenshots
If applicable, add screenshots to help explain your problem.