|
|
|
|
|
by Fiadliel
4579 days ago
|
|
The string concatenation API for Java IS terrible, but see modersky's post for the reasoning. Just don't mistake a bad API for some kind of belief that Scala in general idly converts between types. The weakest point is APIs that use methods defined in java.lang.Object (e.g. toString and equals); they can universally use these methods without restricting the type. Note that if you define a type as a knowledge of what actions can be performed on an object, then no type safety has been lost; toString() is universally available, though it may not do exactly what you want. |
|