Skip to content

Commit a785852

Browse files
committed
Enable workaround for higher versions of MSVC.
1 parent 9c0f914 commit a785852

File tree

1 file changed

+2
-2
lines changed
  • boost/network/protocol/http/message/wrappers

1 file changed

+2
-2
lines changed

boost/network/protocol/http/message/wrappers/port.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,13 @@ struct port_wrapper {
3131

3232
operator port_type() const { return message_.port(); }
3333

34-
#if (_MSC_VER == 1600)
34+
#if (_MSC_VER >= 1600)
3535
// We hack this so that we don't run into the issue of MSVC 2010 not doing the
3636
// right thing when converting/copying Boost.Optional objects.
3737
struct optional_wrapper {
3838
boost::optional<boost::uint16_t> o_;
3939
explicit optional_wrapper(boost::optional<boost::uint16_t> o) : o_(o) {}
40-
operator boost::optional<boost::uint16_t>() { return o_; }
40+
operator boost::optional<boost::uint16_t>() const { return o_; }
4141
};
4242

4343
operator optional_wrapper() const {

0 commit comments

Comments
 (0)