I know that signals can't be assigned or copied, and as far as I can
tell I have made sure that never happens. However, I'm still getting
the warning. We have no warning policy here.
Code followed by compiler output, what do I need to do?:
-------------------------------------------
#include
#include
struct rect {};
struct document
{
document() : changed_sig() {}
virtual rect extents() const = 0;
virtual ~document() {}
boost::signals::connection attach(boost::function const& slot)
{
return changed_sig.connect(slot);
}
private:
boost::signal changed_sig;
document(document const&) {}
document& operator=(document const&) { return *this;}
protected:
void changed(document & d) { changed_sig(d); }
};
int main()
{
}
------------------------------------------------
1>e:\boostvs2\include\boost\signals\trackable.hpp(163) : warning C4512:
'boost::signals::detail::bound_objects_visitor' : assignment operator
could not be generated
1> e:\boostvs2\include\boost\signals\trackable.hpp(66) : see
declaration of 'boost::signals::detail::bound_objects_visitor'
1>e:\boostvs2\include\boost\signals\signal_template.hpp(71) : warning
C4512: 'boost::signals::detail::args1<T1>' : assignment operator could
not be generated
1> with
1> [
1> T1=document &
1> ]
1> e:\boostvs2\include\boost\signals\signal_template.hpp(344) :
see reference to class template instantiation
'boost::signals::detail::args1<T1>' being compiled
1> with
1> [
1> T1=document &
1> ]
1> e:\boostvs2\include\boost\signals\signal_template.hpp(335) :
while compiling class template member function 'void
boost::signal1::operator
()(T1)'
1> with
1> [
1> R=void,
1> T1=document &,
1> Combiner=boost::last_value<void>,
1> Group=int,
1> GroupCompare=std::less<int>,
1> SlotFunction=boost::function
1> ]
1> e:\boostvs2\include\boost\signal.hpp(335) : see reference to
class template instantiation
'boost::signal1' being
compiled
1> with
1> [
1> R=void,
1> T1=document &,
1> Combiner=boost::last_value<void>,
1> Group=int,
1> GroupCompare=std::less<int>,
1> SlotFunction=boost::function
1> ]
1> e:\dev_workspace\experimental\scratch\scratch\main.cpp(19) :
see reference to class template instantiation 'boost::signal<Signature>'
being compiled
1> with
1> [
1> Signature=void (document &)
1> ]
1>Linking...