Reply to post: Re: so wrong

Oracle's Java 15 rides into town, waving the 'we're number one' flag, demands 25th birthday party

overunder Silver badge

Re: so wrong

I'm not a C++ "fan" so I'm on the fence, but just because Java uses predefined overloads doesn't mean you shouldn't be able to overload yourself. You could argue that C++ should force an API of some sort when doing this, but I've never seen a case in C++ were an operator was overloaded and NOT also used in a logical API. Well, I mean you could do it, but that would surely be an intentional Jack-In-The-Box reason (or just flat out evil).

On one hand the way C++ does it can be seen as the absolute shortest way to overload, on the other, tying them to macros can be a thing. As someone who is _NOT_ a C++ pro, it's surely confusing to learn its "When in Rome" semantics, but if you are a pro I can see how it's not a problem.

I don't know. If you learned C++ in the 90's not much has changed honestly. If you've kept C++ on your radar you might even think not much has been added to the STL itself. I sit on the fence, but _IF_ you are a C++ pro, how do you excuse the Javascript IIFE's lamdas... shame... shame on your house.

POST COMMENT House rules

Not a member of The Register? Create a new account here.

  • Enter your comment

  • Add an icon

Anonymous cowards cannot choose their icon


Biting the hand that feeds IT © 1998–2020