Originally posted by: UCJefe
This is against every coding guideline doc I have ever seen. this should really only be used in constructors. If you want a way to visually distinguish your members, use a naming convention. In C++ it's m_var for members, currently in C# I'm using _var. Typing 5 extra chars per variable is a waste of screen real-estate and my eye-power.
Originally posted by: UCJefe
This is against every coding guideline doc I have ever seen. this should really only be used in constructors. If you want a way to visually distinguish your members, use a naming convention. In C++ it's m_var for members, currently in C# I'm using _var. Typing 5 extra chars per variable is a waste of screen real-estate and my eye-power.
Originally posted by: CTho9305
UCJefe has the proper way to do it - naming convention.
Originally posted by: BingBongWongFooey
Originally posted by: CTho9305
UCJefe has the proper way to do it - naming convention.
What exactly makes you say that it is "the proper" way to do it? Last I knew it was a matter of personal opinion.
Personally I agree with kamper. mPoo or m_Poo is hideous IMO and is just a replacement for something that the language will do in a much more uniform and accepted manner.
Technically off topic but in C++ sometimes you actually *need* to use this->, although I don't really remember what for. Something to do with templates or inheritance or something.
But in the end, it's all just personal opinion.
Originally posted by: UCJefe
I never really liked the 'm' either which is why I moved to just _var. But seeing 'this' all over the place is way too much code clutter for me. Call me a code Nazi if you will, but I like it clean.
But in the end, it's all just personal opinion.
It's only personal if you're the only one touching your code. In groups, having a coding standard is very important. Pick something and be consistent.
