Y
Hacker News
new
|
ask
|
show
|
jobs
by
zupa-hu
408 days ago
That exists, it is called a nominal type system, while in your example the language has a structural type system.
Edit: Assuming your example is even statically typed.