On Fri, Jan 6, 2012 at 11:50 AM, Charles Wilson  wrote:

> A FAQ or HOWTO "Support Different Windows OS Versions" would be good as
> well as NEWS , README and list notification.  But why not add a #warning
> if WINVER isn't defined by the user?

Oh, please no. Does Visual Studio issue such warnings? No...and VS users
DO care about whether their code will run only on W7 or can support
Vista/XP/2k/NT/...  This is just part of careful programming on the
windows platform. If you care about compat, you should #define WINVER;
otherwise, a suitable default will be used.


Windows SDK v7.0a does this in WinDef.h:

#ifndef WINVER
#define WINVER 0x0500
#endif /* WINVER */

which argues that we should use a similar default (0x0500) rather than
0x0501.  And that our headers should just define it too, rather than
adding #warning pragmas or similar.


I'll agree with that.  I'm surprised though, WINVER 0x0500 also includes the ME version of OS which is sorely broken.  I guess there are enough users of Windows 2000 server edition to warrant the possibility.

--
Earnie
-- https://sites.google.com/site/earnieboyd