by breckinloggins · 1y ago · 0 comments
Sometimes I long for the days before type theory took over programming language research.
I meant that there was a culture shift around program language research that had given advances in syntax a permanent back seat.
There's not a ton of value to be had in something like Typescript or Python types.
If you only work in small teams, or small projects, I could see this opinion getting formed and maybe agree.
But having worked on large projects... Types are fucking great. So much value exists in simply having a tool that highlights everywhere in the codebase my change impacts.
It makes refactoring at scale possible and expedient in a way that is simply better. Period.
I can be fearless changing things, because I don't have to wonder about all the places my change might have broken - it literally gives me the exact set of files and lines I need to go fix. I don't even have to rely on tests.
It's... Better. It's better even for my personal projects, and it's unimaginably better for my 300 engineer org.
What I don't understand is why, with the myriad of Java-like languages out there (types and all), corporate types still want to Java-ify languages like Ruby... Like, just use Java, Go, Typescript, etc...
It's nice that there's still a language and framework that optimizes for solo devs/small teams and startups.
> It's better even for my personal projects
Does your personal project make money and/or need to be launched quickly? I've also got personal projects in statically typed languages (been playing around a lot with Odin/Vulkan) but those have no due date or expectations. Also declaring types only prevents a very small amount of bugs. And it's not like Ruby doesn't have linters, tests and other tools. Direct feedback from the REPL also makes it easier to write correct code.
Better is also a meaningless word when it comes to software. Does better mean you can ship faster? Or that it's more performant? Unfortunately no language has given us the productivity of a dynamic language with compiled language performance, so everything is a tradeoff...
Correctness is more important (in general and as a benefit of type checking) than optimization. Doing the wrong thing fast is easy, but not valuable.
(Personally I find a type checker tremendously valuable for communicating with myself - and my team, I suppose - about assumptions being made in other parts of the program, which can probably be accounted "correctness".)
Also what's good for enterprise isn't good for everyone.
I get that orgs probably like TS so that newbie devs don't do crazy things in the code, and for more editor hand-holding. But it's not valuable for everyone, if it was actually better than everyone would be using it, not just some people.