Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions mypy/newsemanal/semanal.py
Original file line number Diff line number Diff line change
Expand Up @@ -1676,11 +1676,6 @@ def visit_import_from(self, imp: ImportFrom) -> None:
if self.process_import_over_existing_name(
imported_id, existing_symbol, node, imp):
continue
if (existing_symbol and isinstance(existing_symbol.node, MypyFile) and
existing_symbol.no_serialize): # submodule added to parent module
# Special case: allow replacing submodules with variables. This pattern
# is used by some libraries.
del self.globals[imported_id]
if existing_symbol and isinstance(node.node, PlaceholderNode):
# Imports are special, some redefinitions are allowed, so wait until
# we know what is the new symbol node.
Expand Down