logoalt Hacker News

igregorycayesterday at 2:36 PM1 replyview on HN

I know this is a tangent, but

> Introduce and enforce structs for passing context and input shapes around. So as to stop fighting with NULLs, lack of keys in maps and other maddening cases that inflate your coding lines for no other reason than programming languages not having higher-order constructs on well-researched and mostly resolved computer science problems

Amen to that.


Replies

pdimitaryesterday at 5:53 PM

It's not that much of a tangent tbf. It's one of the things that is an endless churn in millions of codebases out there and yet no core programming language team has the courage and the grit to solve this problem.

Those who tried are only doing it in mostly academic/toy languages which is a damned shame. We _really_ need those constructs, compile-time enforced, in commercial codebases, like 25 years ago at least!

People are trying everywhere though but I've witnessed CTOs getting cold feet and fearing their codebase will get too abstract or hard to maintain when they hire the next dev.

Group-think and conformism and fear of change, demonstrated live, every day. :/

So yep -- amen to that indeed.