New submission from Batuhan Taskaya <isidenti...@gmail.com>:

Since the annotations are processed just like all other expressions in the 
symbol table, the generated entries for functions etc. This would result with 

def foo():
    for number in range(5):
        foo: (yield number)
    return number

foo()

returning a generator / coroutine (depending on yield/yield from/await usage). 
Is this something we want to keep or maybe tweak the symbol table generator to 
not to handle annotations (since there are also more subtle issues regarding 
analysis of cell / free vars).

----------
messages: 383647
nosy: BTaskaya, gvanrossum
priority: normal
severity: normal
status: open
title: PEP 563: Should the behavior change for yield/yield from's

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue42725>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to