Is it possible to create types like e.g. String(20)
in scala?
The aim would be to have compiler checks for things like:
a: String(20)
b: String(30)
a = b; // throws a compiler exception when no implicit conversion is available
b= a; // works just fine
Note: It doesn't need to be/named String