Amaury Forgeot d'Arc added the comment: I know two real usages:
- the nose and py.test packages accept a generator function, as described here: http://codespeak.net/py/dist/test.html#generative-tests-yielding-more-tests http://somethingaboutorange.com/mrl/projects/nose/#test-generators. functions are collected with the help of the "inspect" module. - the twisted framework use "inlineCallbacks": a function executes an asynchronous operation and yields; execution is resumed when the operation gets its results. "inlineCallbacks" is actually a a decorator. Both cases make the difference between a generator function and a regular function, even if it returns a generator. And they don't want to execute the function to know it... ---------- nosy: +amaury.forgeotdarc __________________________________ Tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue1916> __________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com