2
0
mirror of https://github.com/boostorg/asio.git synced 2026-01-27 06:32:08 +00:00

Target workaround at non-Apple objective-c++ compilers only, as the previous

workaround broke those platforms. Pragmas push_macro and pop_macro are only
available on gcc 4.4 or later, so use plain ol' #define/#undef instead.


[SVN r66289]
This commit is contained in:
Christopher Kohlhoff
2010-10-30 22:45:29 +00:00
parent 200db06b39
commit ddc92ac35f
2 changed files with 14 additions and 8 deletions

View File

@@ -31,9 +31,12 @@
# pragma pack (pop)
# endif
# if defined(__OBJC__)
# pragma pop_macro("Protocol")
# pragma pop_macro("id")
# if defined(__OBJC__) && !defined(__APPLE_CC__)
# if defined(BOOST_ASIO_OBJC_WORKAROUND)
# undef Protocol
# undef id
# undef BOOST_ASIO_OBJC_WORKAROUND
# endif
# endif
#elif defined(__KCC)

View File

@@ -31,11 +31,14 @@
# pragma pack (push, 8)
# endif
# if defined(__OBJC__)
# pragma push_macro("Protocol")
# define Protocol cpp_Protocol
# pragma push_macro("id")
# define id cpp_id
# if defined(__OBJC__) && !defined(__APPLE_CC__)
# if !defined(BOOST_ASIO_DISABLE_OBJC_WORKAROUND)
# if !defined(Protocol) && !defined(id)
# define Protocol cpp_Protocol
# define id cpp_id
# define BOOST_ASIO_OBJC_WORKAROUND
# endif
# endif
# endif
#elif defined(__KCC)