logoalt Hacker News

alkonaut • yesterday at 11:23 PM • 2 replies • view on HN

If I wrote a useful library a few years back and it targeted net472 and net6.0 then… it just keeps targeting those? I can still use it from a net48 and net10.0 app just fine?


Replies

feoren • today at 10:45 AM

No, you cannot use it "just fine". There could be any number of breaking changes to your library between .NET 6 and .NET 10, and you're not guaranteed that a build will catch them. Have you painstakingly reviewed every line of code against every breaking change that Microsoft introduces with every new runtime?

I personally saw, this week, an internal library that worked in .NET 8 but threw runtime errors when built in .NET 10. Previously working code can just break in subtle ways, and it could be anywhere, in any library in your chain of dependencies. In an ecosystem where you are forced to upgrade every 2 years, this is not OK. This is not a feasible way to build an ecosystem of interconnected libraries, and I believe the only reason it's not more painfully obvious is that .NET Core just isn't that old yet. This is going to hurt more and more as time goes on.

There's a reason Microsoft was obsessed with backward compatibility between 1980 and 2016. This never happened with .NET Framework. I don't know why Microsoft suddenly decided backward compatibility no longer matters, but it's a big mistake.

metaltyphoon • today at 12:38 AM

Yes you can, so I don't know what OP is complaining about.

➕ show 1 reply