Hi! > > lst_prod test; > > for_each(l.begin(), l.end(), test); > > The functor used by for_each() is a copy of "test". Yes... Looks like I need [more] RTFM... > Try this instead: > > lst_prod test = for_each(l.begin(), l.end(), lst_prod()); Thanks, it works as expected. Sorry for a silly question...