> You cannot be serious. Globals are bad all the time.

While I may not agree with making the handle global in this case it should
be noted that you cannot avoid globals. main( ) and WinMain( ) use, as do
the functions to initialize a C/C++ app and to perform cleanup on exit.
And
then there are the globals that we see in just about any C++
framework/wrapper library (like MFC) that if we were to use it, we cannot
avoid it's globals.

They cannot be avoided.

Absolutely, but that doesn't mean you should introduce more of your own.

Woe woe woe. First you say "Globals are bad *ALL THE TIME*." Then you accept globals that are in the framework. The whole point of my above paragraph was meant to counter your statement, and you agree with my paragraph.


But at the same time I agree their usage should be limited. My globals
were
always prefixed with g_ and were only made global if their wasn't any
other
hierarchical object that should claim ownership.

Then they should probably be paramtised from above.

I didn't quite catch that one.

We'll not mention how bad Hungarian notation is. ;-)

And not to mention how useful it is too!

/dev


_______________________________________________ msvc mailing list msvc@beginthread.com See http://beginthread.com/mailman/listinfo/msvc_beginthread.com for subscription changes, and list archive.

Reply via email to