Skip to content

Commit

Permalink
Fix find occurrences flag
Browse files Browse the repository at this point in the history
Fixes python#15527

Namespaces are untyped, so this only gets caught by mypyc.

I didn't know about this feature, looks like it's explicitly documented
as experimental. Guess no one has used it in a long, long time.
  • Loading branch information
hauntsaninja committed Jun 27, 2023
1 parent ef87305 commit 2aa46bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mypy/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -1336,7 +1336,7 @@ def set_strict_flags() -> None:

# Set build flags.
if special_opts.find_occurrences:
state.find_occurrences = special_opts.find_occurrences.split(".")
state.find_occurrences = tuple(special_opts.find_occurrences.split("."))
assert state.find_occurrences is not None
if len(state.find_occurrences) < 2:
parser.error("Can only find occurrences of class members.")
Expand Down

0 comments on commit 2aa46bb

Please sign in to comment.