[Boost-bugs] [Boost C++ Libraries] #1703: [asio] Compiler warnings on VC8/9 + warning level 4

Subject: [Boost-bugs] [Boost C++ Libraries] #1703: [asio] Compiler warnings on VC8/9 + warning level 4
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2008-03-22 00:08:48


#1703: [asio] Compiler warnings on VC8/9 + warning level 4
---------------------------------------------------------+------------------
 Reporter: Richard Webb <richard.webb_at_[hidden]> | Owner: chris_kohlhoff
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: asio
  Version: Boost Development Trunk | Severity: Cosmetic
 Keywords: |
---------------------------------------------------------+------------------
 Running the ASIO regression tests on vc8/9 with warning level 4 produces a
 large number of 4512 (assignment operator could not be generated)
 warnings:

 {{{
 boost/asio/detail/task_io_service.hpp(344) : warning C4512:
 'boost::asio::detail::task_io_service<Task>::task_cleanup' : assignment
 operator could not be generated
 boost/asio/detail/task_io_service.hpp(369) : warning C4512:
 'boost::asio::detail::task_io_service<Task>::handler_cleanup' : assignment
 operator could not be generated
 boost/asio/buffered_read_stream.hpp(206) : warning C4512:
 'boost::asio::buffered_read_stream<Stream>::fill_handler<ReadHandler>' :
 assignment operator could not be generated
 boost/asio/buffered_read_stream.hpp(295) : warning C4512:
 'boost::asio::buffered_read_stream<Stream>::read_some_handler<MutableBufferSequence,ReadHandler>'
 : assignment operator could not be generated
 boost/asio/detail/buffer_resize_guard.hpp(64) : warning C4512:
 'boost::asio::detail::buffer_resize_guard<Buffer>' : assignment operator
 could not be generated
 boost/asio/buffered_write_stream.hpp(169) : warning C4512:
 'boost::asio::buffered_write_stream<Stream>::flush_handler<WriteHandler>'
 : assignment operator could not be generated
 boost/asio/buffered_write_stream.hpp(253) : warning C4512:
 'boost::asio::buffered_write_stream<Stream>::write_some_handler<ConstBufferSequence,WriteHandler>'
 : assignment operator could not be generated
 boost/asio/impl/write.ipp(146) : warning C4512:
 'boost::asio::detail::write_handler<AsyncWriteStream,ConstBufferSequence,CompletionCondition,WriteHandler>'
 : assignment operator could not be generate
 boost/asio/impl/read.ipp(160) : warning C4512:
 'boost::asio::detail::read_handler<AsyncReadStream,MutableBufferSequence,CompletionCondition,ReadHandler>'
 : assignment operator could not be generated
 boost/asio/impl/read_until.ipp(335) : warning C4512:
 'boost::asio::detail::read_until_delim_handler<AsyncReadStream,Allocator,ReadHandler>'
 : assignment operator could not be generated
 boost/asio/impl/read_until.ipp(492) : warning C4512:
 'boost::asio::detail::read_until_delim_string_handler<AsyncReadStream,Allocator,ReadHandler>'
 : assignment operator could not be generated

 boost/asio/detail/win_iocp_io_service.hpp(588) : warning C4512:
 'boost::asio::detail::win_iocp_io_service::auto_work' : assignment
 operator could not be generated
 boost/asio/detail/strand_service.hpp(254) : warning C4512:
 'boost::asio::detail::strand_service::invoke_current_handler' : assignment
 operator could not be generated
 boost/asio/detail/strand_service.hpp(295) : warning C4512:
 'boost::asio::detail::strand_service::post_next_waiter_on_exit' :
 assignment operator could not be generated

 boost/asio/strand.hpp(178) : warning C4512:
 'boost::asio::io_service::strand' : assignment operator could not be
 generated

 boost/asio/detail/wrapped_handler.hpp(170) : warning C4512:
 'boost::asio::detail::rewrapped_handler<Handler,Context>' : assignment
 operator could not be generated
 boost/asio/detail/wrapped_handler.hpp(129) : warning C4512:
 'boost::asio::detail::wrapped_handler<Dispatcher,Handler>' : assignment
 operator could not be generated
 boost/asio/detail/bind_handler.hpp(108) : warning C4512:
 'boost::asio::detail::binder2<Handler,Arg1,Arg2>' : assignment operator
 could not be generated

 }}}

 plus a couple of other types:

 {{{
 boost/asio/detail/select_reactor.hpp(110) : warning C4100: 'descriptor' :
 unreferenced formal parameter
 boost/asio/detail/win_iocp_socket_service.hpp(1575) : warning C4100:
 'bytes_transferred' : unreferenced formal parameter

 boost/asio/detail/select_reactor.hpp(69) : warning C4127: conditional
 expression is constant
 }}}

 plus a couple from the tests themselves:

 {{{
 ip\tcp.cpp(194) : warning C4996:
 'boost::asio::basic_socket<Protocol,SocketService>::cancel': By default,
 this function always fails with operation_not_supported when used on
 Windows XP, Windows Server 2003, or earlier. Consult documentation for
 details.
 ip\udp.cpp(99) : warning C4996:
 'boost::asio::basic_socket<Protocol,SocketService>::cancel': By default,
 this function always fails with operation_not_supported when used on
 Windows XP, Windows Server 2003, or earlier. Consult documentation for
 details.
 }}}

 Attached is a patch that silences most of these for me.

--
Ticket URL: <http://svn.boost.org/trac/boost/ticket/1703>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.


This archive was generated by hypermail 2.1.7 : 2017-02-16 18:49:57 UTC