codegear.hpp 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  1. // (C) Copyright John Maddock 2001 - 2003.
  2. // (C) Copyright David Abrahams 2002 - 2003.
  3. // (C) Copyright Aleksey Gurtovoy 2002.
  4. // Use, modification and distribution are subject to the
  5. // Boost Software License, Version 1.0. (See accompanying file
  6. // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  7. // See http://www.boost.org for most recent version.
  8. // CodeGear C++ compiler setup:
  9. #if !defined( BOOST_WITH_CODEGEAR_WARNINGS )
  10. // these warnings occur frequently in optimized template code
  11. # pragma warn -8004 // var assigned value, but never used
  12. # pragma warn -8008 // condition always true/false
  13. # pragma warn -8066 // dead code can never execute
  14. # pragma warn -8104 // static members with ctors not threadsafe
  15. # pragma warn -8105 // reference member in class without ctors
  16. #endif
  17. //
  18. // versions check:
  19. // last known and checked version is 0x610
  20. #if (__CODEGEARC__ > 0x610)
  21. # if defined(BOOST_ASSERT_CONFIG)
  22. # error "Unknown compiler version - please run the configure tests and report the results"
  23. # else
  24. # pragma message( "Unknown compiler version - please run the configure tests and report the results")
  25. # endif
  26. #endif
  27. // CodeGear C++ Builder 2009
  28. #if (__CODEGEARC__ <= 0x610)
  29. # define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
  30. # define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS
  31. # define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
  32. # define BOOST_NO_PRIVATE_IN_AGGREGATE
  33. # define BOOST_NO_TWO_PHASE_NAME_LOOKUP
  34. # define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE
  35. # define BOOST_NO_USING_TEMPLATE
  36. // we shouldn't really need this - but too many things choke
  37. // without it, this needs more investigation:
  38. # define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS
  39. # define BOOST_NO_TYPENAME_WITH_CTOR // Cannot use typename keyword when making temporaries of a dependant type
  40. # define BOOST_NO_NESTED_FRIENDSHIP // TC1 gives nested classes access rights as any other member
  41. // Temporary hack, until specific MPL preprocessed headers are generated
  42. # define BOOST_MPL_CFG_NO_PREPROCESSED_HEADERS
  43. # ifdef NDEBUG
  44. // fix broken <cstring> so that Boost.test works:
  45. # include <cstring>
  46. # undef strcmp
  47. # endif
  48. // fix broken errno declaration:
  49. # include <errno.h>
  50. # ifndef errno
  51. # define errno errno
  52. # endif
  53. #endif
  54. //
  55. // C++0x macros:
  56. //
  57. #define BOOST_HAS_CHAR16_T
  58. #define BOOST_HAS_CHAR32_T
  59. #define BOOST_HAS_LONG_LONG
  60. // #define BOOST_HAS_ALIGNOF
  61. #define BOOST_HAS_DECLTYPE
  62. #define BOOST_HAS_EXPLICIT_CONVERSION_OPS
  63. // #define BOOST_HAS_RVALUE_REFS
  64. #define BOOST_HAS_SCOPED_ENUM
  65. // #define BOOST_HAS_STATIC_ASSERT
  66. #define BOOST_HAS_STD_TYPE_TRAITS
  67. #define BOOST_NO_AUTO_DECLARATIONS
  68. #define BOOST_NO_AUTO_MULTIDECLARATIONS
  69. #define BOOST_NO_CONCEPTS
  70. #define BOOST_NO_CONSTEXPR
  71. #define BOOST_NO_DEFAULTED_FUNCTIONS
  72. #define BOOST_NO_DELETED_FUNCTIONS
  73. #define BOOST_NO_EXTERN_TEMPLATE
  74. #define BOOST_NO_INITIALIZER_LISTS
  75. #define BOOST_NO_LAMBDAS
  76. #define BOOST_NO_NULLPTR
  77. #define BOOST_NO_RAW_LITERALS
  78. #define BOOST_NO_RVALUE_REFERENCES
  79. #define BOOST_NO_STATIC_ASSERT
  80. #define BOOST_NO_TEMPLATE_ALIASES
  81. #define BOOST_NO_UNICODE_LITERALS
  82. #define BOOST_NO_VARIADIC_TEMPLATES
  83. //
  84. // TR1 macros:
  85. //
  86. #define BOOST_HAS_TR1_HASH
  87. #define BOOST_HAS_TR1_TYPE_TRAITS
  88. #define BOOST_HAS_TR1_UNORDERED_MAP
  89. #define BOOST_HAS_TR1_UNORDERED_SET
  90. #define BOOST_HAS_MACRO_USE_FACET
  91. #define BOOST_NO_INITIALIZER_LISTS
  92. // On non-Win32 platforms let the platform config figure this out:
  93. #ifdef _WIN32
  94. # define BOOST_HAS_STDINT_H
  95. #endif
  96. //
  97. // __int64:
  98. //
  99. #if !defined(__STRICT_ANSI__)
  100. # define BOOST_HAS_MS_INT64
  101. #endif
  102. //
  103. // check for exception handling support:
  104. //
  105. #if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS)
  106. # define BOOST_NO_EXCEPTIONS
  107. #endif
  108. //
  109. // all versions have a <dirent.h>:
  110. //
  111. #if !defined(__STRICT_ANSI__)
  112. # define BOOST_HAS_DIRENT_H
  113. #endif
  114. //
  115. // all versions support __declspec:
  116. //
  117. #if !defined(__STRICT_ANSI__)
  118. # define BOOST_HAS_DECLSPEC
  119. #endif
  120. //
  121. // ABI fixing headers:
  122. //
  123. #ifndef BOOST_ABI_PREFIX
  124. # define BOOST_ABI_PREFIX "boost/config/abi/borland_prefix.hpp"
  125. #endif
  126. #ifndef BOOST_ABI_SUFFIX
  127. # define BOOST_ABI_SUFFIX "boost/config/abi/borland_suffix.hpp"
  128. #endif
  129. //
  130. // Disable Win32 support in ANSI mode:
  131. //
  132. # pragma defineonoption BOOST_DISABLE_WIN32 -A
  133. //
  134. // MSVC compatibility mode does some nasty things:
  135. // TODO: look up if this doesn't apply to the whole 12xx range
  136. //
  137. #if defined(_MSC_VER) && (_MSC_VER <= 1200)
  138. # define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
  139. # define BOOST_NO_VOID_RETURNS
  140. #endif
  141. #define BOOST_COMPILER "CodeGear C++ version " BOOST_STRINGIZE(__CODEGEARC__)