Live data from Hacker News

Welcome to C# 9.0

devblogs.microsoft.com

181–190 of 196 posts

Re: Welcome to C# 9.0

#181
post #17

How does the .NET ecosystem fare these days compared to Java's? Whatever the differences between the languages, on the surface of things it looks like one must be insane not to use Java: https://projects.apache.org/projects.html?language

Ignoring the flawed comparison, the Java ecosystem is better. However, recently, I see first class providers for .NET popping up with most project and the ecosystem growing dramatically. It is no longer a showstopper, it is more a reduced choice situation.

What .NET still is not really good in, is first party apps. There is no Kafka or Kubernetes programmed in .NET.

Re: Welcome to C# 9.0

#182
post #25

Earlier quoted context omitted.

Now you can test C# 9 with Visual Studio Preview and .NET 5.0 preview https://visualstudio.microsoft.com/vs/preview/ https://dotnet.microsoft.com/download/dotnet/5.0

Note: you can't use C# 9 with .NET 5 preview 4; you'll have to wait until .NET 5 preview 5 is released. You can use it with the latest VS preview, though.

yes but when it comes out in full, will VS 2019 still support c# 9 or will I have to buy new VS?

Re: Welcome to C# 9.0

#183

I still think C# is one of, if not the best of designed languages exist. Even it moves in much smaller steps than it was before I think it's for good. I left .NET land at 6.0 and .NET 4.x versions mostly because of Windows eco-system (small open source community, almost no alternatives to out of the MS things, bad linux support). Since that I've been working with Java, Swift,JS, Python, Golang and I still think that…

> It's amazing how the language advances over years

I think that with the latest improvements (from v7 to now) Microsoft is trying to "fill the gap" between F# and C#, and let C# developers embrace functional paradigms (at least, some of) without switching to F# itself.

Re: Welcome to C# 9.0

#184
post #41

Earlier quoted context omitted.

It's about trade off. A language that keep getting new features every year, will make some users happy, but will lose compiler speed and it will be harder to learn.

I love C# and have used it since the beginning (my online handles are often VisualCSharp), but I do worry about the cognitive burden of remembering idioms and dealing with multiple ways to do the same thing. This is already a huge issue with C++, and now it's slowly happening to C#. I work with many, many developers--some overseas--that are still in the string.Format era. The language is starting to show some warts d…

> I do worry about the cognitive burden of remembering idioms and dealing with multiple ways to do the same thing

To me, VS 2019 refactoring suggestions and Roslynator extensions helped a lot to learn and use new syntax capabilities and idioms: you write code in "the same old way" and then often roslyn is able to convert this code using new features, often in a concise, readable but undebuggable way :)

Re: Welcome to C# 9.0

#185
post #106

Earlier quoted context omitted.

Oh, cool, I didn't notice that! Still, they are playing catch-up here.

I mean... if you go that route then I would say Kotlin isn't really ready to be used as a production language in most places due to the severe lack of tooling, especially when it comes to things like static analysis. Sure ktlint is there, but the rules library is lacking. So from that perspective, Kotlin is playing catch-up.

Static analysis is the only weak point of kotlin that I'm aware of.. Intellij Idea has by default something that might be considered as static analysis.

There is also detekt but it's true it is inferior to solution that Java has. https://github.com/detekt/detekt

PMD is targeting kotlin initial support for their next major release https://github.com/pmd/pmd/issues/419

I've answered a jetbrains survey recently and they revealed they are working on a new product that would be a full fledged static analyser, maybe this would solve the issue?

Re: Welcome to C# 9.0

#186
post #144

Earlier quoted context omitted.

There is nothing insane here. All depends on context. Games are known to be developed in C# and the amount of those dwarfs Java's counterpart. There are other areas with the affinity of "insanity" leaning either way.

Amazing Princess Sarah vs. Minecraft, sure.

Not sure if you're knocking C# credentials as a games programming language but if you are you're wrong to do so.

Re: Welcome to C# 9.0

#187

Earlier quoted context omitted.

> Works well everywhere Perhaps it's gotten better - TBH I haven't checked in years - but it used to be a horrible bug ridden mess for doing things aimed at Linux (i.e. via mono).

To answer your question first: It's faster on Linux than Windows now (marginally) and completly stable on Linux. I've been running a .net core systemd service for 9 months with 0 downtime (not using the new HostedService class though). It hasn't leaked any memory at all, it's still running perfectly even though it opens thousands of files and thousands of connections to a web service every hour. It's just a process t…

Very interesting. One of the reasons I like the JVM is that it has a good cross-platform GUI system. Does the .NET windows GUI work in Linux as well?

Re: Welcome to C# 9.0

#188

Earlier quoted context omitted.

It really is wonderful. Used it at work years ago and still miss it dearly. The only thing I don't miss is the lack of community. Many things you can get for free in Java/Python cost money in Microsoft land. Even common stuff like decent excel and PDF support. Its getting better but was still the case last time I looked. What C# needs is Java interop. The VM and bytecode structures are similar enough for it to work.…

Funny you should say that because I wrote an application that has both Excel and PDF output and both libraries were free on NuGet.

there's free libraries, I used a bunch of them. I guess I'm just asking you to trust me that's its not nearly as good as in Java. C# is a better language, there's no question. But I jumped off the MS bandwagon years ago because there just wasn't the community support that Java has, for better (or probably) worse

Re: Welcome to C# 9.0

#189

I still think C# is one of, if not the best of designed languages exist. Even it moves in much smaller steps than it was before I think it's for good. I left .NET land at 6.0 and .NET 4.x versions mostly because of Windows eco-system (small open source community, almost no alternatives to out of the MS things, bad linux support). Since that I've been working with Java, Swift,JS, Python, Golang and I still think that…

It really is wonderful. Used it at work years ago and still miss it dearly. The only thing I don't miss is the lack of community. Many things you can get for free in Java/Python cost money in Microsoft land. Even common stuff like decent excel and PDF support. Its getting better but was still the case last time I looked. What C# needs is Java interop. The VM and bytecode structures are similar enough for it to work.…

It's been a lot better for a long time.

There -are- still a couple sore points, PDF comes to mind. But there are at least a couple different good projects out there for working with Excel at this point.

Bigger problem is a larger portion of C# developers and their managers are frightened of shifting away from the Microsoft blessed stack. That's what creates this chicken-egg situation where good projects don't have enough community behind them because there aren't enough people using them.

GC in C# isn't perfect but works fairly well if you understand it. There's plenty of ways to write minimal or zero-allocation code and it's gotten a lot easier with the newer Span types.

Monitoring though... yeah The first time I learned about Blackbox and the like I got a bit jealous :)

Re: Welcome to C# 9.0

#190

Earlier quoted context omitted.

To answer your question first: It's faster on Linux than Windows now (marginally) and completly stable on Linux. I've been running a .net core systemd service for 9 months with 0 downtime (not using the new HostedService class though). It hasn't leaked any memory at all, it's still running perfectly even though it opens thousands of files and thousands of connections to a web service every hour. It's just a process t…

Very interesting. One of the reasons I like the JVM is that it has a good cross-platform GUI system. Does the .NET windows GUI work in Linux as well?

Almost. :)

Right now there is Xamarin Forms which has a community maintained Linux layer.

You can use that today if you write a Xamarin forms app.

From the Microsoft side of things, no, you can't just write a winforms app and use it in Linux.

However, they have announced MAUI which basically lets you write XML/XAML UI Declarations that are platform agnostic and can be translated into the various layers (such as Xamarin Forms.) I believe that's supposed to be a thing sometime late this year or early next (don't quote me on that!)

Other projects to look into are AvaloniaUI and Uno. Those are community projects that try to give you cross platform UI today.

Post reply on HN