Skip to content

Commit 2844601

Browse files
committed
Mention relevant test cases
1 parent 5a41b0e commit 2844601

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

mypy/checker.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4965,6 +4965,8 @@ def can_widen_in_scope(self, name: NameExpr, orig_type: Type) -> bool:
49654965
49664966
Globals can only be widened from within a function if the original type
49674967
is None (backward compat with partial type handling of `x = None`).
4968+
4969+
See test cases testNewRedefineGlobalVariableNoneInit[1-4], for example.
49684970
"""
49694971
if (
49704972
name.kind == GDEF

0 commit comments

Comments
 (0)