Consider the following snippet:
class Foo {
public:
Foo( int Value );
// other stuff
};
std::list< boost::shared_ptr< Foo > > ListOfFoo = list_of( 1 )( 2 )( 3 )( 4 )( 5 );
This does not work out of the box. What is the simplest way to make this work, or is there any method to assign values to ListOfFoo
as simple as that?