8 #ifndef IMPBASE_NULLPTR_H
9 #define IMPBASE_NULLPTR_H
11 #include <IMP/base/base_config.h>
12 #include <boost/config.hpp>
27 const std::nullptr_t
nullptr;
30 #elif defined(BOOST_NO_CXX11_NULLPTR) || defined(BOOST_NO_NULLPTR)
34 #if __GNUC__ &&__GNUC__ == 4 && __GNUC_MINOR__ >= 6
35 IMP_GCC_PRAGMA(diagnostic push)
36 IMP_GCC_PRAGMA(diagnostic ignored
"-Wc++0x-compat")
41 operator O *()
const {
42 return static_cast<O *
>(NULL);
50 inline bool operator==(O *a, nullptr_t o) {
51 return a ==
static_cast<O *
>(o);
54 inline bool operator!=(O *a, nullptr_t o) {
55 return a !=
static_cast<O *
>(o);
57 extern IMPBASEEXPORT
const nullptr_t
nullptr;
59 #if __GNUC__ &&__GNUC__ == 4 && __GNUC_MINOR__ >= 6
60 IMP_GCC_PRAGMA(diagnostic pop)
64 extern const void *
const nullptr;