"return" in def

Benjamin musiccomposition at gmail.com
Sun Dec 28 16:36:54 EST 2008


On Dec 28, 1:35 pm, Steven D'Aprano <st... at REMOVE-THIS-
cybersource.com.au> wrote:
> The second thing I think is that maybe the function is a generator, and
> so I look for a yield.

You shouldn't, though; Generators can't contain any return statement.




More information about the Python-list mailing list