5 ms·
Thank goodness there is no operator overloading. I maintain 15 year old java codebases and am very happy they did not add user defined operators...
by kochthesecond 8y ago
Thank goodness there is no operator overloading. I maintain 15 year old java codebases and am very happy they did not add user defined operators...
- jVinc 8y agoI always find this an odd reason to be against usable features. I have inherited codebases in extremely confined languages as have I inherited codebases in very permitting high-level languages Python, and never have I though "Thank good this language decided to restrict its reach in order to confine the programmer to a smaller subset which made it harder for him to mess up." Often have I though "My good, if only the language had better supported what the programmer is trying to implement himself through horrible hacks, then I wouldn't be sitting here trying to wonder exactly what mistakes he made that casuses everything to crash inexplicably."
- sharpercoder 8y agoI guess the culture around a language matters significantly. For instance, there is quite a specific culture around the Rust community/language. The focus on the language ergonomics is also reflected in many packages. Same goes for the mutability/immutability aspect of code. A second example of this culture is the go language. I read a few repo's, and the same style of programming is seemingly applied throughout. For the Java case, I can actually see operator overloading going haywaire over many codebases. The same as overengineering is a typical trait associated with Java.
- willtim 8y agoArithmetic expressions on BigInteger and BigDecimal currently look like an OOP parody. I cannot believe there are folks willing to defend this decision. Even Sun couldn't resist overloading '+'.