[C++]
I agree with the "use it when you have to" brigade. Decorating code unnecessarily with this isn't a great idea because the compiler won't warn you when you forget to do it. This introduces potential confusion for people expecting this to always be there, i.e. they'll have to think about it.
So, when would you use it? I've just had a look around some random code and found these examples (I'm not passing judgement on whether these are good things to do or otherwise):
- Passing "yourself" to a function.
- Assigning "yourself" to a pointer or something like that.
- Casting, i.e. up/down casting (safe or otherwise), casting away constness, etc.
- Compiler enforced disambiguation.