Boost C++ Libraries: Ticket #11779: Boost.Lockfree: Implicit conversion loses integer precision warnings https://svn.boost.org/trac10/ticket/11779 <p> Xcode Version 7.1 (7B91b) </p> <p> When using <code>boost::lockfree::queue</code> I get the following implicit conversion warnings: </p> <pre class="wiki">In file included from /foobar/source/foundation/concurrency/task_queue.cpp:11: In file included from /foobar/libraries/boost/install.osx/include/boost/lockfree/queue.hpp:21: In file included from /foobar/libraries/boost/install.osx/include/boost/lockfree/detail/freelist.hpp:23: In file included from /foobar/libraries/boost/install.osx/include/boost/lockfree/detail/tagged_ptr.hpp:18: /foobar/libraries/boost/install.osx/include/boost/lockfree/detail/tagged_ptr_ptrcompression.hpp:59:30: warning: implicit conversion loses integer precision: 'int' to 'tag_t' (aka 'unsigned short') [-Wconversion] ret.tag[tag_index] = tag; ~ ^~~ /foobar/libraries/boost/install.osx/include/boost/lockfree/detail/tagged_ptr_ptrcompression.hpp:78:13: note: in instantiation of member function 'boost::lockfree::detail::tagged_ptr&lt;boost::lockfree::queue&lt;std::__1::packaged_task&lt;void ()&gt; *, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_&gt;::node&gt;::pack_ptr' requested here ptr(pack_ptr(p, t)) ^ In file included from /foobar/source/foundation/concurrency/task_queue.cpp:11: /foobar/libraries/boost/install.osx/include/boost/lockfree/queue.hpp:202:15: note: in instantiation of member function 'boost::lockfree::detail::tagged_ptr&lt;boost::lockfree::queue&lt;std::__1::packaged_task&lt;void ()&gt; *, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_&gt;::node&gt;::tagged_ptr' requested here head_(tagged_node_handle(0, 0)), ^ /foobar/source/foundation/concurrency/task_queue.cpp:40:29: note: in instantiation of member function 'boost::lockfree::queue&lt;std::__1::packaged_task&lt;void ()&gt; *, boost::parameter::void_, boost::parameter::void_, boost::parameter::void_&gt;::queue' requested here TaskQueueContext(void) : Queue(128) {} }}} ^ </pre> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/11779 Trac 1.4.3 Markus Tue, 11 Apr 2017 09:01:12 GMT <link>https://svn.boost.org/trac10/ticket/11779#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11779#comment:1</guid> <description> <p> I get the same warning when using boost::lockfree::stack with boost v 1.63.0, and it is a problem since we have warning-as-errors rules when compiling. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>timblechmann</dc:creator> <pubDate>Tue, 11 Apr 2017 12:46:43 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/11779#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/11779#comment:2</guid> <description> <p> could you submit a pull request? </p> </description> <category>Ticket</category> </item> </channel> </rss>