Hacker News new | ask | show | jobs
by oaiey 1544 days ago
It looks like C# and Java are now developed in parallel with the same features.
2 comments

I was about to say the same thing.

As someone who moved from Java to C# around 2013, I always felt that C# was close to Java but with less bad parts and more good parts. Looks like Java's now borrowing a lot of the nicer features which is good to see.

There are still so many nice exclusive features in C# that I definitely wouldn't want to go back to Java any time soon though (properties, powerful tuples, null coalescing, interpolated strings, ...).

I feel similarly - though I think it's more the case that Java considers things a lot longer and considers the implications before simply adding them.

Java needed string interpolation forever before _finally_ getting something. There are parts of C# that I think are going to look like a good idea at the time, but turned out not so great. Extension methods is one, and async/await is another. In fact, if Project Loom ever, finally, actually ships it'll make the whole c# code colouring thing look like the abomination that it is.

I actually like the code colouring. It is clear indication that the function is optimized for asynchronoty and that I need to take care how to properly integrate then to achieve the goal. Is the Async suffix stupid: yes. Is a clear indication needed: imho yes
It has always been like that.

Java attributes and compiler plugins took their inspiration from .NET early version.

Default method interfaces in C# come from Java, LINQ vs streams, JIT / PGO caches,...

That is why it is still relatively easy to do consulting across both platforms.

I think the interaction between the small c# design team vs. JEP process plays hand in hand.