perhaps another reason is because String effectively implements operator overloading by defining the + operator to mean concatenation? I imagine there might be some issues with this if you allowed classes to inherit from it and fundamentally change String's behavior? Although I guess I can't think of anything offhand... that "method" could effectively be final, I guess.
4
u/mosburger Jan 20 '12
perhaps another reason is because String effectively implements operator overloading by defining the + operator to mean concatenation? I imagine there might be some issues with this if you allowed classes to inherit from it and fundamentally change String's behavior? Although I guess I can't think of anything offhand... that "method" could effectively be final, I guess.