How much "boilerplate tax" different languages have: a 400M LOC analysis (boyter.org)
from codeinabox@programming.dev to programming@programming.dev on 07 Feb 03:18
https://programming.dev/post/45351949

cross-posted from: lemmy.bestiver.se/post/908809

Comments

#programming

threaded - newest

FishFace@piefed.social on 07 Feb 10:12 next collapse

I call boilerplate having to repeat types because there’s no type inference, but this is not captured here.

Kolmogorov complexity would be a good denominator, but you’d end up with a higher boilerplate score if your language just uses longer keywords

FizzyOrange@programming.dev on 07 Feb 14:25 next collapse

Yeah I think just counting fully unique lines is going to really capture the repetitiveness of a language. I think you’d get more accurate results just asking people using pairwise ranking.

tyler@programming.dev on 07 Feb 17:36 collapse

Like someone on lobste.rs says:

Or an unrelated point: who do you believe, this data or your lying eyes? Java and Perl are not similar in their verbosity!

How in the world does Ruby have a lower DRYness than Java? This person’s code just does not work. And Java is almost as high as Kotlin? I’ve done conversion of millions of lines of Java to Kotlin. Just a direct conversion alone will save you 20% of your lines, and that’s without even bothering to switch to Kotlin code style, so that’s with Streams and massive if statements rather than pattern matching.

LaTeX only has 67% uniqueness? Huh???

This article has major problems.