Subject: Re: [boost] [cpo-proposal] presentation of the idea
From: Thorsten Ottosen (thorsten.ottosen_at_[hidden])
Date: 2013-08-20 04:30:23
On 19-08-2013 22:18, Larry Evans wrote:
> The 1st attachment uses the offset method for the container
> and has the:
> template<typename F> void push_back(F const&);
> The output is in 2nd attachment.
You work fast :-)
Since the classes in a hierarchy is normally not copyable (though
perhaps cloneable), I would make push_back like this:
template< class T, typename... Args >
void push_back( Args... args )
// A. static assert that T* is convertiable to Base*
// B. all the usual stuff
// C. in-place construct from std::forward(args)...