Re:Least Known C++ Keywords
by lelele on Sunday January 09, 2011 @09:01AM
(#2085467)
If you don't use any of these keyword, then please do not present yourself as a C++ programmer at all. Some are quite infrequent - I've never used "auto", "register" - but I can't think about any serious C++ OOP code lacking "explicit".
Re:Least Known C++ Keywords
by srean on Sunday January 09, 2011 @09:24AM
(#2085507)
The auto keyword has been repurposed to do some basic type inferencing. It helps save a lot of typing (both senses of the word apply here). This is in c++0x and most compilers already implement this usage of auto.
Re:Least Known C++ Keywords
by srean on Sunday January 09, 2011 @07:01AM
(#2085356)
I am not a good or a professional C++ programmer by any means, but still I find these quite basic. I think you will encounter them in the first 5 items or so of Meyers.
Re:Least Known C++ Keywords
by cpeterso on Tuesday January 11, 2011 @02:03PM
(#2093033)
Has anyone here actually seen (or written) C++ code that used the and, not, or or keywords (from iso646.h)? These keywords seem cleaner and are standard, yet I have never seen (or dared use) them in practice. In my day job, I write code that must be portable across a dozen platforms, so I am paranoid about using "unusual" C++ features.
Re:Least Known C++ Keywords
by casterleigh on Monday January 10, 2011 @02:53PM
(#2089516)
Kind of reminded me what a gigantic, arcane mess C++ really is. It's not enough that there are half a dozen different semantics of "const" -- the "mutable" keyword let's you break the convention of the const function (not changing member values) without a user of your interface ever knowing about it.
Re:Least Known C++ Keywords
by jaywalker on Wednesday January 12, 2011 @02:24AM
(#2095325)
Isn't it the cost of having direct access to the memory? Can you name another language where you can control so many aspects of the system, and still remain "clean"?