• Zangoose@lemmy.world
    link
    fedilink
    arrow-up
    1
    ·
    11 hours ago

    As someone who has worked with a pretty large C# codebase and several smaller ones, I’ve found it to be one of the least efficient languages to program in. This is maybe not a technical fault of the language, but the way Microsoft encourages developing C# means that once you get past a certain point even simple MRs will have 10-20 files changed. There is sooooooooo much boilerplate caused by .NET that even things like Java Spring Boot just don’t have (and even then I’d consider Java to be a pretty bloated language in terms of boilerplate).

    That’s ignoring the fact that the ecosystem surrounding .NET is a lot more enterprise-y, meaning a good portion of libraries require paid licenses to use.

    • dependencyinjection@discuss.tchncs.de
      link
      fedilink
      arrow-up
      1
      ·
      7 hours ago

      Yeah, I totally get where you’re coming from. I think it depends on what you mean by ‘efficient.’ If we’re talking about runtime performance and memory management, C# and .NET are generally very efficient: JIT compilation, span/memory optimisations, and the garbage collector all make it competitive with Java in most workloads.

      Where I agree with you is in developer efficiency: .NET projects can definitely get heavy with boilerplate, especially in enterprise setups with lots of layers, dependency injection, and config-heavy patterns. That’s not necessarily a language issue, but more a combination of the framework conventions, Microsoft’s enterprise guidance, and patterns like MVC/WebAPI scaffolding.