Comment by treyd
You can express a lot of concepts just through types in languages with richer type systems.
You can express a lot of concepts just through types in languages with richer type systems.
You can enforce them (statically) by other means if you’re determined enough, eg by using lint rules which enforce type-like semantics which the type system itself doesn’t express.
Even without a rich type system you can express a lot of things just through naming.
You just can't enforce those assumptions.