add generator, generator function support.