Re:C++ Fun with(out) keyword explicit
by srean on Monday November 30, 2015 @11:20AM
(#10650132)
I hear you about abusing overloading, but given how succinct it can make the syntax, I would not want to give it up. Its mix of a pragmatic and philosophical question. Just because some people may abuse it, do you make those suffer who can use it properly. Things get muddy when the set of people who can use it properly is really small. As far as C++ operator overloading is concerned I don't think that is the case. Some enlightened newbies go overboard but most handle it fine enough.
Something about D I like quite a bit is that they lean towards making these confusing things errors rather than have special case rules. C++ is full of complicated special case rules. Just consider template specialization and function overloading. The tie breaking rule is just insane. D community usually prefers making them errors rather blessing one of those ties to be kosher, till the community manages to come up with a compelling easy to remember rule.
Something about D I like quite a bit is that they lean towards making these confusing things errors rather than have special case rules. C++ is full of complicated special case rules. Just consider template specialization and function overloading. The tie breaking rule is just insane. D community usually prefers making them errors rather blessing one of those ties to be kosher, till the community manages to come up with a compelling easy to remember rule.