8 ms·
I really don't see how C# is decent anymore, can someone change my mind? I was all about it in the 2010-2013 days, but over time it just became more bloated and
by jimmy1 8y ago
I really don't see how C# is decent anymore, can someone change my mind? I was all about it in the 2010-2013 days, but over time it just became more bloated and bloated. It's the new C++, where it tries to be everything for everyone.
Every time a new version comes out theres a 500 page tome of all the new features added. Did we really need all those features? I would love it if I saw a new version of a language come out and it removes language features, wouldn't that be a change!
It still has all the annoyances of java (the first thing you see in any C# file is a laundry list of imports), I am not convinced the profiling tooling is better. I will preface this with I am still bitter about the initial .NET core rollout which was a crapshoot and had no parity whatsoever with .NET Framework.
- quickthrower2 8y agoIn the newer C# features there is a lot of syntax sugar, and you don't really have to use them. I don't think it is any more bloated than in 2013, and most C# code bases wont look much different to back then.
- alelefant 8y agoYou are obviously free to dislike C#, but it seems silly to say they should stop adding features or should remove features. > Did we really need all those features? If you don't need them, don't use them. I've found the new features to be great. nameof, string interpolation, property initializers, exception filters, static imports, null propagator. And if you haven't used the language in awhile going back to 5.0 the async await features are fantastic. 7.1 introduced async Main which we've started using in console apps. I use all of these features every day. > I would love it if I saw a new version of a language come out and it removes language features Why, exactly?
- bryanrasmussen 8y ago1. Some people dislike languages with a large instruction set 2. I will propose that programming languages are like anything else created by humans - some parts great, some parts not that great. Furthermore some parts of a language are used more than other parts, it should be hoped that the parts least used in any particular language are parts of that language that are not that great. Given these things it might be reasonable that some time you saw a new version of a language in which they said Feature X really sort of didn't make sense and anyway hardly anyone ever used it so we are removing Feature X. Adjust code accordingly. (probably there should be deprecation stage of a year or so with warnings)
- pjmlp 8y agoEven human languages aren't not fully used. There are multiple levels of understanding, regionalisms and specialized technical terms that few get to use.
- jimmy1 8y agoAnd that works in language -- its terrible when you are trying to make computers do very specific things in specific scenarios. It leads to hiring nightmares as well. "Oh I write language X in this style, not familiar with your style"
- Faark 8y agoMy simple go-to example is tuples. They are on the third attempt to introduce that feature. First was generic Tuple.Create. Did not support naming individual fields. Then came anonymous classes. Those could only be used where type is inferred. The latest are using braces... most powerful, but also syntactically quite different from what came before. I like C# adding new features, and understand some try-and-see-what-sticks is unavoidable. But I don't understand them not deprecating the old versions. And still wonder if improving an earlier version would have been possible/better.
- eksemplar 8y agoIt’s not, not really, but it runs a lot of enterprise and reschooling developers is really expensive. I know, because we’re in the process of going from almost exclusively c# to mostly node.js and powershell scripts with orchestra and SSIS. The fact that Microsoft keeps doing things like core 1, the 2, xamarin and now this web assembly stuff made the business case for changing better though. Because staying up to date on c# has also become expensive. Still, stuff like AD and ADFS, msSQL and windows servers are the backbone in a lot of enterprise, and C# integrates really easily in that environment. I still think node.js, powershell and SSIS does it better, but I can certainly see why c# is still a thing.
- Rapzid 8y agoI mean.. I really like TypeScript and nodejs as an every language that I can use and promote without too much push back but "Does it better" isn't a qualifier that comes to mind. Sure I can come up with specific areas that I enjoy more about nodejs/TypeScript, but I can also come up with just as many for C#/.Net: * Async/Await implementation is pretty much superior * Real threading; great for task pools as well * Task local storage; something the nodejs community is very interested in but thus far only lives in hacks on obscure run-time features * Speed? * Integers?; come on man * Linq/Entity Framework(though these should mostly be possible to implement in TypeScript now) If I had my druthers I'd be using F# though, TBH.
- eksemplar 8y agoI don’t think C# has superior async functionality, it used to, and certainly had for a long time, but not today. Threading and tasks add unnecessary complexity. Speed? What speed, this web assembly example is more than 5mb of .net libraries. We make apps for people on less than 3g. Entity is one of the worst, least productive and most error prone frameworks we’ve ever had in our stack. Especially code first. Linq almost made us stick with C# forever.
- tluyben2 8y ago> Entity is one of the worst, least productive I think that hits the nail on the head; I never got why anyone used that. We never did and we have been using c# for a long time (all over to Core now) and all the horror stories never applied to our work, I think, because we never touched entity.
- wvenable 8y ago> Every time a new version comes out theres a 500 page tome of all the new features added. That's not really true, the list of features in each version is pretty tight and focused: https://docs.microsoft.com/en-us/dotnet/csharp/whats-new/csharp-version-history https://docs.microsoft.com/en-us/dotnet/csharp/whats-new/csh...
- jve 8y agoI just realized maybe op was thinking about .NET release notes? They are lengthier. https://docs.microsoft.com/en-us/dotnet/framework/whats-new https://docs.microsoft.com/en-us/dotnet/framework/whats-new But .NET is a framework that is written in C# and extensively used by C# and not a language.
- deleted 8y ago[deleted]
- cm2187 8y agoAgree. I have some beefs with the fragmentation of the framework though. I kind of hope that in the end we will end up with only two frameworks: mono on wasm for clients, and .net core for server/high performance clients. But what is true is that there starts to be a lot of overlap and inconsistencies between multiple generations of the framework. You have object methods vs generics. You have async/callback methods vs async/await. You have ref/out returning methods vs valuetuple returning functions. etc. The language is starting to show its age even though the .net team has been adding to the syntax sparingly.
- jve 8y ago> I really don't see how C# is decent anymore How come it was decent once but not anymore? As others said, you are probably exaggerating by saying new version comes with 500 page tome. However it is a joy for me to program in C#. Super-consistent language. And my favorite feature "LINQ" really gets rid of loops and loops and maybe more nested loops. Interfaces, generics - all great features, decently implemented under the hood.
- eropple 8y agoCalling LINQ a "feature" still feels very off to me. It's a set of library functions with some very strange and, at least in my neck of the woods strongly discouraged, SQL-ish syntax that you can use if you like making it harder to understand what your code is actually doing. The library functions are...fine, to be clear, aside from the inconsistent-for-the-sake-of-inconsistent naming (and I know they want to ape SQL, but 'Select' is a map function, sorry). But...they're library functions. You should expect that stuff to exist in a programming language worth a fart. C#'s feature changes over the last few years have been marginal. They nibble at the edges while stuff like record classes--an actually and materially valuable thing that significantly improves the writing of immutable and functional code--have been punted for multiple versions now. C# is Java now, in a way it wasn't when it was younger. It's afraid of change and in being afraid of change has slowed to a crawl. Such is probably the way of most programming languages and ecosystems. But it is a little sad for me to see.
- thrower123 8y agoThe weird special-case LINQ syntax appears to have receded and I don't recall seeing it in the wild for some time. Hopefully we can just all agree that was a bad idea and it can get officially deprecated and go away in future versions.
- wvenable 8y agoYeah, I mostly use the methods to do LINQ and rarely use the linq syntax -- but -- it's actually quite powerful and if you have to do a reasonably complex query it's much easier to compose and read in that syntax than the alternative mess of method calls and lambdas.
- manigandham 8y agoC# release notes are very focused and definitely not 500 pages. You can look at the major features per version in a single page and there are now point releases for smaller and faster iterations. Many changes have also made C# much more productive and expressive by letting you do more with less. Every language has imports but the strong typing and amazing tooling makes it a non-issue. Use VS or Rider and you can type out entire programs in a few minutes without ever worrying about imports.
- plaguuuuuu 8y agoC# has a super solid feature set, built up over years of development. When you know C# well you can really lean on it - today I was applying list operators to iterators over the results of database queries that hadn't even been evaluated yet, so that I could apply them just to a specific page of the result set. That's pretty cool - LINQ is a beast combined with the ienumerable/iqueryable interfaces. C# might have minor drawbacks (ok single inheritance is a pain) but it works better than most languages in its class. The only thing that makes me feel inadequate is seeing some really advanced level Haskell code :o
- fbarred 8y ago"I would love it if I saw a new version of a language come out and it removes language features, wouldn't that be a change!" "I am still bitter about the initial .NET core rollout which was a crapshoot and had no parity whatsoever with .NET Framework." Those two statements seem to be in direct contradiction with each other. Would you like iron-clad parity, or would you like to break compatibility in an effort to shed bloat?
- alkonaut 8y agoC# is still very much a decent language, but it's not as shiny as it used to be. I have worked professionally with .NET and C# since the 1.0beta and I have to agree: it's not that good any more. Not because it's gained so much bloat or because it has gotten worse, but because its ecosystem has been fractured so many times I stopped counting. The core ordeal is just the last in a series of disruptions and the previous one was Roslyn. These aren't bad initiatives, it's just that they aren't ready. Roslyn is barely working in VS together with the project system (which is odd given it was shipped first in VS2015)! I applaud ms for developing more in the open, but the constant renaming and churn of everything is tiring. But all that aside, C# is still decent, the only thing making it less shiny now is that we realized that OO is a promise that didn't deliver. I don't want to program another line without proper algebraic types for example - yet here we are.
- eksemplar 8y agoI’m not sure who’s downvoting you, but it sure isn’t managers who’s paid for people getting re-educated in asp, then mvc and razor, then web-api, then xamarin, then core 1, then core 2 and that’s just to name a few. Hell, it’s still not easy for people to deploy a .net core web api and run it in an IIS installed with basic settings. You can laugh at it, but that’s 80% of the damn workforce who doesn’t know how to do that. I mean, the JS environment changes, but I haven’t had to pay for anyone getting reschooled since we swapped to JS.
- felixfbecker 8y ago> I would love it if I saw a new version of a language come out and it removes language features, wouldn't that be a change! That is exactly .NET Core
- neilsimp1 8y agoThat didn't really remove language features though. That removed framework features.
- felixfbecker 8y agoWhat language features would you like to see removed?
- sctb 8y agoWe detached this subthread from https://news.ycombinator.com/item?id=18136654 https://news.ycombinator.com/item?id=18136654.