a typo of generator (in fact ordinary functions) fixed