News for hackers. Stuff that matters.
Re:Parse, Don't Validate (2019) by rileymichael on Tuesday February 10, 2026 @11:50AM (#46962700)
this is likely an ecosystem sort of thing. if your language gives you the tools to do so at no cost (memory/performance) then folks will naturally utilize those features and it will eventually become idiomatic code. kotlin value classes are exactly this and they are everywhere: https://kotlinlang.org/docs/inline-classes.html
Re:Parse, Don't Validate (2019) by gr4vityWall on Tuesday February 10, 2026 @01:01PM (#46964029)
Haxe has a really elegant solution to this in the form of Abstracts[0][1]. I wonder why this particular feature never became popular in other languages, at least to my knowledge.

0 - https://code.haxe.org/category/abstract-types/color.html

1 - https://haxe.org/manual/types-abstract.html