[Boost-bugs] [Boost C++ Libraries] #12078: Warnings in boost/core/swap.hpp when using nvcc

Subject: [Boost-bugs] [Boost C++ Libraries] #12078: Warnings in boost/core/swap.hpp when using nvcc
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2016-03-19 16:00:54


#12078: Warnings in boost/core/swap.hpp when using nvcc
----------------------------------------------+----------------------------
 Reporter: Karl Ljungkvist <k.ljungkvist@…> | Type: Bugs
   Status: new | Milestone: To Be
Component: None | Determined
 Severity: Problem | Version: Boost
                                              | Development Trunk
                                              | Keywords:
----------------------------------------------+----------------------------
 I get the following warning when I compile .cu files which uses the
 boost/core/swap.hpp file:

 {{{
 ~/sw/boost/include/boost/core/swap.hpp(36): warning: calling a __host__
 function from a __host__ __device__ function is not allowed
           detected during:
             instantiation of "void boost_swap_impl::swap_impl(T &, T &)
 [with T=boost::signals2::detail::foreign_shared_ptr_impl_base *]"
 (56): here
             instantiation of "void boost::swap(T1 &, T2 &) [with
 T1=boost::signals2::detail::foreign_shared_ptr_impl_base *,
 T2=boost::signals2::detail::foreign_shared_ptr_impl_base *]"
 ~/sw/boost/include/boost/signals2/detail/foreign_ptr.hpp(111): here
 }}}

 I get this even with the most recent git version (commit 3a94cde). The
 attached program gives this error when compiling like this:

 {{{ nvcc -I ~/sw/boost/include test_swap.cu}}}

 I use CUDA 7.5 and g++ 4.9.2.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/12078>
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:50:19 UTC