pop_options.hpp 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. //
  2. // detail/pop_options.hpp
  3. // ~~~~~~~~~~~~~~~~~~~~~~
  4. //
  5. // Copyright (c) 2003-2022 Christopher M. Kohlhoff (chris at kohlhoff dot com)
  6. //
  7. // Distributed under the Boost Software License, Version 1.0. (See accompanying
  8. // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  9. //
  10. // No header guard
  11. #if defined(__COMO__)
  12. // Comeau C++
  13. #elif defined(__DMC__)
  14. // Digital Mars C++
  15. #elif defined(__INTEL_COMPILER) || defined(__ICL) \
  16. || defined(__ICC) || defined(__ECC)
  17. // Intel C++
  18. # if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
  19. # if !defined(ASIO_DISABLE_VISIBILITY)
  20. # pragma GCC visibility pop
  21. # endif // !defined(ASIO_DISABLE_VISIBILITY)
  22. # endif // (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
  23. #elif defined(__clang__)
  24. // Clang
  25. # if defined(__OBJC__)
  26. # if !defined(__APPLE_CC__) || (__APPLE_CC__ <= 1)
  27. # if defined(ASIO_OBJC_WORKAROUND)
  28. # undef Protocol
  29. # undef id
  30. # undef ASIO_OBJC_WORKAROUND
  31. # endif
  32. # endif
  33. # endif
  34. # if !defined(_WIN32) && !defined(__WIN32__) && !defined(WIN32)
  35. # if !defined(ASIO_DISABLE_VISIBILITY)
  36. # pragma GCC visibility pop
  37. # endif // !defined(ASIO_DISABLE_VISIBILITY)
  38. # endif // !defined(_WIN32) && !defined(__WIN32__) && !defined(WIN32)
  39. # pragma GCC diagnostic pop
  40. # pragma pop_macro ("emit")
  41. # pragma pop_macro ("signal")
  42. # pragma pop_macro ("slot")
  43. #elif defined(__GNUC__)
  44. // GNU C++
  45. # if defined(__MINGW32__) || defined(__CYGWIN__)
  46. # pragma pack (pop)
  47. # endif
  48. # if defined(__OBJC__)
  49. # if !defined(__APPLE_CC__) || (__APPLE_CC__ <= 1)
  50. # if defined(ASIO_OBJC_WORKAROUND)
  51. # undef Protocol
  52. # undef id
  53. # undef ASIO_OBJC_WORKAROUND
  54. # endif
  55. # endif
  56. # endif
  57. # if (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
  58. # if !defined(ASIO_DISABLE_VISIBILITY)
  59. # pragma GCC visibility pop
  60. # endif // !defined(ASIO_DISABLE_VISIBILITY)
  61. # endif // (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || (__GNUC__ > 4)
  62. # pragma GCC diagnostic pop
  63. # pragma pop_macro ("emit")
  64. # pragma pop_macro ("signal")
  65. # pragma pop_macro ("slot")
  66. #elif defined(__KCC)
  67. // Kai C++
  68. #elif defined(__sgi)
  69. // SGI MIPSpro C++
  70. #elif defined(__DECCXX)
  71. // Compaq Tru64 Unix cxx
  72. #elif defined(__ghs)
  73. // Greenhills C++
  74. #elif defined(__BORLANDC__) && !defined(__clang__)
  75. // Borland C++
  76. # pragma option pop
  77. # pragma nopushoptwarn
  78. # pragma nopackwarning
  79. #elif defined(__MWERKS__)
  80. // Metrowerks CodeWarrior
  81. #elif defined(__SUNPRO_CC)
  82. // Sun Workshop Compiler C++
  83. #elif defined(__HP_aCC)
  84. // HP aCC
  85. #elif defined(__MRC__) || defined(__SC__)
  86. // MPW MrCpp or SCpp
  87. #elif defined(__IBMCPP__)
  88. // IBM Visual Age
  89. #elif defined(_MSC_VER)
  90. // Microsoft Visual C++
  91. //
  92. // Must remain the last #elif since some other vendors (Metrowerks, for example)
  93. // also #define _MSC_VER
  94. # pragma warning (pop)
  95. # pragma pack (pop)
  96. # if defined(__cplusplus_cli) || defined(__cplusplus_winrt)
  97. # if defined(ASIO_CLR_WORKAROUND)
  98. # undef generic
  99. # undef ASIO_CLR_WORKAROUND
  100. # endif
  101. # endif
  102. # pragma pop_macro ("emit")
  103. # pragma pop_macro ("signal")
  104. # pragma pop_macro ("slot")
  105. #endif