David --

Just to clarify: the C++ 98 spec requires that NULL evaluate to 0, which is 
where I suspect VC++ is having trouble. In C++ 11 it must be 0 or a value of 
type nullptr_t. In C is it allowed to also be ((VOID *) 0). See 
http://www.cplusplus.com/reference/cstring/NULL/

Having said that: I think your change makes sense.
 
Tim

-----Original Message-----
From: David F. [mailto:[email protected]] 
Sent: Tuesday, February 12, 2013 8:49 PM
To: [email protected]
Subject: [edk2] CPP Build Issue VC NULL

For visual studio the define for NULL in base.h should be

#if defined(__cplusplus)
#define NULL 0
#else
#define NULL  ((VOID *) 0)
#endif

------------------------------------------------------------------------------
Free Next-Gen Firewall Hardware Offer
Buy your Sophos next-gen firewall before the end March 2013 and get the 
hardware for free! Learn more.
http://p.sf.net/sfu/sophos-d2d-feb
_______________________________________________
edk2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-devel

------------------------------------------------------------------------------
Free Next-Gen Firewall Hardware Offer
Buy your Sophos next-gen firewall before the end March 2013 
and get the hardware for free! Learn more.
http://p.sf.net/sfu/sophos-d2d-feb
_______________________________________________
edk2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to