
16 Apr
2007
16 Apr
'07
9:08 p.m.
Christian Henning wrote:
Thanks Peter, this makes sense. But just image I cannot change the print function's interface. For example I have to interface with MFC's CComboBox::AddString( LPCTSTR lpszString ) . Do you think there is still a way to have just one for_each() loop? My guts tell me no.
Not without writing your own wrapper function void print2( std::string const & s ) { print( s.c_str() ); } and binding that instead of 'print'.