[issue47202] Feature request: Throw an error when making impossible evaluation against an empty list

2022-04-02 Thread Luminair
Luminair added the comment: Thank you for the quick response Jelle! I do like mypy, and I will file this with them. Good luck with the migration to GitHub :) -- ___ Python tracker <https://bugs.python.org/issue47

[issue47202] Feature request: Throw an error when making impossible evaluation against an empty list

2022-04-02 Thread Luminair
New submission from Luminair : Below are four examples of impossible code that operates on nothing. The latter two continue silently, throwing no errors. I saw a bug sneak by because of this. I wonder if it is within the scope of Python's design to throw Exceptions in these situations? x