For those of you who name you member variables with no special notation like m_foo or foo_, how do you name parameters to your ctors and setters?>
I always do this:
Obj(int foo) : foo(foo) {}
I used to play games with appending funny symbols until one time I got hit by this:
Obj(Bar& b) : b_(b_) {}
Can you see the mistake? (Yes, b_ is a private member reference variable). It compiled without a warning. Cost me 3 days of debugging (I was a green programmer then).
Now I always use the same name to avoid typos (and subsequent crashes) like that. There is no ambiguity inside the initialization list. This part of the language was designed just for this case, so take advantage of it.