Commit 88cf8e0
authored
fix: optimize overloaded signatures check (#20378)
I've observed numerous calls to `expand_callable_variants` during the
investigation of the related issue. However, expanding all the variants
for parametrized classes can be time-consuming. Therefore, we should
only expand callable variants once. This optimization reduces the
processing time from approximately 400 seconds to 7 seconds when using
non-compiled mypy in the provided case.
Refs: nipunn1313/mypy-protobuf#7071 parent ab63d64 commit 88cf8e0
1 file changed
+2
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8751 | 8751 | | |
8752 | 8752 | | |
8753 | 8753 | | |
| 8754 | + | |
8754 | 8755 | | |
8755 | | - | |
| 8756 | + | |
8756 | 8757 | | |
8757 | 8758 | | |
8758 | 8759 | | |
| |||
0 commit comments