On Mon, Apr 5, 2021 at 10:46 AM Terry Reedy <tjre...@udel.edu> wrote:

> If there were a 'dead
> (unreachable) code' exception, a reader or compiler would have to
> analyze each use of 'yield' and decide whether it is reachable or not.
>

It's also subject to how hard the compiler feels like trying in any given
release.  Many compilers have simple unreachable code warnings.

But to do a 100% accurate job of yield detection would be equivalent to the
halting problem, which is a classic problem in computer science that cannot
be solved 100% accurately in finite time.
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to