From: Stéphane C. <ste...@gm...> - 2011-02-14 23:09:37
|
I'm compiling my test app with Boost v1.45 and cpp-netlib 0.8.1. I see the following warnings in the build logs: In file included from /usr/local/include/cpp-netlib/boost/network/message.hpp:16, from /usr/local/include/cpp-netlib/boost/network.hpp:15, from /home/stephane/workspace/[cut]: /usr/local/include/cpp-netlib/boost/network/message/directives.hpp: In constructor ‘boost::network::source_directive_base::normal_visitor<Message>::normal_visitor(const Message&)’: /usr/local/include/cpp-netlib/boost/network/message/directives.hpp:26: warning: declaration of ‘message’ shadows a member of 'this' [-Wshadow] /usr/local/include/cpp-netlib/boost/network/message/directives.hpp: In constructor ‘boost::network::source_directive_base::pod_visitor<Message>::pod_visitor(const Message&)’: /usr/local/include/cpp-netlib/boost/network/message/directives.hpp:26: warning: declaration of ‘message’ shadows a member of 'this' [-Wshadow] And: In file included from /usr/local/include/cpp-netlib/boost/network/protocol/http/response.hpp:15, from /usr/local/include/cpp-netlib/boost/network/protocol/http.hpp:15, from /usr/local/include/cpp-netlib/boost/network/protocol.hpp:15, from /usr/local/include/cpp-netlib/boost/network.hpp:16, from /home/stephane/workspace/[cut]: /usr/local/include/cpp-netlib/boost/network/protocol/http/message/directives/status_message.hpp: In constructor ‘boost::network::http::status_message_directive_base::normal_visitor<Message>::normal_visitor(const Message&)’: /usr/local/include/cpp-netlib/boost/network/protocol/http/message/directives/status_message.hpp:15: warning: declaration of ‘message’ shadows a member of 'this' [-Wshadow] /usr/local/include/cpp-netlib/boost/network/protocol/http/message/directives/status_message.hpp: In constructor ‘boost::network::http::status_message_directive_base::pod_visitor<Message>::pod_visitor(const Message&)’: /usr/local/include/cpp-netlib/boost/network/protocol/http/message/directives/status_message.hpp:15: warning: declaration of ‘message’ shadows a member of 'this' [-Wshadow] And: In file included from /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/message_traits.hpp:53, from /usr/local/include/cpp-netlib/boost/network/protocol/http/traits.hpp:15, from /usr/local/include/cpp-netlib/boost/network/protocol/http/message.hpp:16, from /usr/local/include/cpp-netlib/boost/network/protocol/http/response.hpp:36, from /usr/local/include/cpp-netlib/boost/network/protocol/http.hpp:15, from /usr/local/include/cpp-netlib/boost/network/protocol.hpp:15, from /usr/local/include/cpp-netlib/boost/network.hpp:16, from /home/stephane/workspace/[cut]: /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/delimiters.ipp: At global scope: /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/delimiters.ipp:17: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/delimiters.ipp:22: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/delimiters.ipp:27: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] In file included from /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/message_traits.hpp:54, from /usr/local/include/cpp-netlib/boost/network/protocol/http/traits.hpp:15, from /usr/local/include/cpp-netlib/boost/network/protocol/http/message.hpp:16, from /usr/local/include/cpp-netlib/boost/network/protocol/http/response.hpp:36, from /usr/local/include/cpp-netlib/boost/network/protocol/http.hpp:15, from /usr/local/include/cpp-netlib/boost/network/protocol.hpp:15, from /usr/local/include/cpp-netlib/boost/network.hpp:16, from /home/stephane/workspace/[cut]: /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:16: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:21: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:26: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:31: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:36: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:41: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:46: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:51: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:56: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:61: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:66: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:71: warning: type qualifiers ignored on function return type [-Wignored-qualifiers] |
From: Dean M. B. <mik...@gm...> - 2011-02-15 00:37:52
|
2011/2/15 Stéphane Charette <ste...@gm...>: > I'm compiling my test app with Boost v1.45 and cpp-netlib 0.8.1. I see the > following warnings in the build logs: > > In file included from > /usr/local/include/cpp-netlib/boost/network/message.hpp:16, > from /usr/local/include/cpp-netlib/boost/network.hpp:15, > from /home/stephane/workspace/[cut]: > /usr/local/include/cpp-netlib/boost/network/message/directives.hpp: In > constructor > ‘boost::network::source_directive_base::normal_visitor<Message>::normal_visitor(const > Message&)’: > /usr/local/include/cpp-netlib/boost/network/message/directives.hpp:26: > warning: declaration of ‘message’ shadows a member of 'this' [-Wshadow] > /usr/local/include/cpp-netlib/boost/network/message/directives.hpp: In > constructor > ‘boost::network::source_directive_base::pod_visitor<Message>::pod_visitor(const > Message&)’: > /usr/local/include/cpp-netlib/boost/network/message/directives.hpp:26: > warning: declaration of ‘message’ shadows a member of 'this' [-Wshadow] > Which compiler are you using and on what platform? Also are you using bjam to build or are you using CMake? It also looks like you're using it in your own application. It would be great if you can post a minimal example that would help me better diagnose the problem. > And: > > In file included from > /usr/local/include/cpp-netlib/boost/network/protocol/http/response.hpp:15, > from > /usr/local/include/cpp-netlib/boost/network/protocol/http.hpp:15, > from > /usr/local/include/cpp-netlib/boost/network/protocol.hpp:15, > from /usr/local/include/cpp-netlib/boost/network.hpp:16, > from /home/stephane/workspace/[cut]: > /usr/local/include/cpp-netlib/boost/network/protocol/http/message/directives/status_message.hpp: > In constructor > ‘boost::network::http::status_message_directive_base::normal_visitor<Message>::normal_visitor(const > Message&)’: > /usr/local/include/cpp-netlib/boost/network/protocol/http/message/directives/status_message.hpp:15: > warning: declaration of ‘message’ shadows a member of 'this' [-Wshadow] > /usr/local/include/cpp-netlib/boost/network/protocol/http/message/directives/status_message.hpp: > In constructor > ‘boost::network::http::status_message_directive_base::pod_visitor<Message>::pod_visitor(const > Message&)’: > /usr/local/include/cpp-netlib/boost/network/protocol/http/message/directives/status_message.hpp:15: > warning: declaration of ‘message’ shadows a member of 'this' [-Wshadow] > > And: > > In file included from > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/message_traits.hpp:53, > from > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits.hpp:15, > from > /usr/local/include/cpp-netlib/boost/network/protocol/http/message.hpp:16, > from > /usr/local/include/cpp-netlib/boost/network/protocol/http/response.hpp:36, > from > /usr/local/include/cpp-netlib/boost/network/protocol/http.hpp:15, > from > /usr/local/include/cpp-netlib/boost/network/protocol.hpp:15, > from /usr/local/include/cpp-netlib/boost/network.hpp:16, > from /home/stephane/workspace/[cut]: > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/delimiters.ipp: > At global scope: > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/delimiters.ipp:17: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/delimiters.ipp:22: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/delimiters.ipp:27: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > In file included from > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/message_traits.hpp:54, > from > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits.hpp:15, > from > /usr/local/include/cpp-netlib/boost/network/protocol/http/message.hpp:16, > from > /usr/local/include/cpp-netlib/boost/network/protocol/http/response.hpp:36, > from > /usr/local/include/cpp-netlib/boost/network/protocol/http.hpp:15, > from > /usr/local/include/cpp-netlib/boost/network/protocol.hpp:15, > from /usr/local/include/cpp-netlib/boost/network.hpp:16, > from /home/stephane/workspace/[cut]: > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:16: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:21: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:26: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:31: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:36: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:41: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:46: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:51: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:56: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:61: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:66: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > /usr/local/include/cpp-netlib/boost/network/protocol/http/traits/impl/headers.ipp:71: > warning: type qualifiers ignored on function return type > [-Wignored-qualifiers] > This is a new one on me. I think 0.9-devel has been developed with the -Wall option, but this one looks like you're using the -pedantic option (is that correct?). I'll try building/running the tests with -Wall on 0.8.1 and see if I can reproduce. Also, do you mind filing issues on https://github.com/cpp-netlib/cpp-netlib/issues so that we can track the progress on this? Thanks for reporting Stephane! -- Dean Michael Berris about.me/deanberris |