Ticket #2372: boost_asio.patch
File boost_asio.patch, 1.2 KB (added by , 14 years ago) |
---|
-
read_until.hpp
30 30 #include <boost/asio/basic_streambuf.hpp> 31 31 #include <boost/asio/error.hpp> 32 32 33 #include <boost/detail/workaround.hpp> 34 33 35 namespace boost { 34 36 namespace asio { 35 37 36 38 namespace detail 37 39 { 40 #if BOOST_WORKAROUND(__CODEGEARC__, BOOST_TESTED_AT(0x610)) 38 41 template <typename T> 39 42 struct has_result_type 40 43 { 44 template <typename U> struct inner 45 { 46 struct big { char a[100]; }; 47 static big helper(U, ...); 48 static char helper(U, typename U::result_type* = 0); 49 }; 50 static const T& ref(); 51 enum { value = (sizeof((inner<const T&>::helper)((ref)())) == 1) }; 52 }; 53 #else 54 template <typename T> 55 struct has_result_type 56 { 41 57 struct big { char a[100]; }; 42 58 template <typename U> static big helper(U, ...); 43 59 template <typename U> static char helper(U, typename U::result_type* = 0); 44 60 static const T& ref(); 45 61 enum { value = (sizeof((helper)((ref)())) == 1) }; 46 62 }; 63 #endif 47 64 } // namespace detail 48 65 49 66 /// Type trait used to determine whether a type can be used as a match condition