janjones

Joined 6 years ago

Karma
401
Submissions
85
Member since
Sep 22
Roslyn (C# compiler) dev at Microsoft.

https://github.com/jjonescz

https://janjones.me

View on Hacker News

Recent submissions

Comment · 1 month ago
Comment · 9 months ago
Clarified my comment a bit, thanks
Comment · 9 months ago
Comment · 10 months ago
Yes, it's contextual. There is more details in this section of the article: Naming Conflicts with Existing Class Members
Comment · 1 year ago
Comment · 1 year ago
Comment · 1 year ago
> You can't do much of anything in .NET without referencing Nuget assemblies.

And referencing NuGet assemblies is of course supported via the #:package directive. It's just that referencing DLLs directly is not a common scenario, hence it's not supported for now (but can be added later).

> Agreeing with others, '#r "nuget:' should at least be an option.

Thanks, we hear you and plan to add support for it, see https://github.com/dotnet/sdk/issues/49199

> And otherwise (but I guess regarless if you stick with this syntax) you will have to add another tab to Nuget called "dotnet run". "Script & Interactive" is already present in Nuget and shows the #r syntax for a reference.

Agree but also note that the ".NET CLI" tab which tells you to run "dotnet add package" should also work in near future, see https://github.com/dotnet/sdk/issues/49200.

Comment · 1 year ago
Comment · 1 year ago
Comment · 1 year ago
Referencing other projects is currently out of scope (and might always be, file based programs are intended to be simple), you can convert file based programs to full projects though to regain full functionality.
Comment · 1 year ago
.NET interactive uses a dialect of C# - the script dialect. With file based apps, we strive to use the standard C#, so you can convert file based apps to full projects at any time.
Comment · 1 year ago
Assembly references are not really a mainline scenario, hence we support nuget package references only for now. And `#r` is just too opaque (it comes from old times when assembly references were the norm).

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton