Describe the issue:
E.g. resize is using ... as a default value instead of False.
Not sure if default arguments have any value for running static type check on the code, but having them at hand is very convenient when reading/writing code.
|
@overload |
|
def resize(self, new_shape: _ShapeLike, /, *, refcheck: builtins.bool = ...) -> None: ... |
|
@overload |
|
def resize(self, *new_shape: SupportsIndex, refcheck: builtins.bool = ...) -> None: ... |

Reproduce the code example:
import numpy as np
x = np.ones(3)
# Hover over `.resize`.
x.resize(6)
Python and NumPy Versions:
2.2.3
3.11.9 (tags/v3.11.9:de54cf5, Apr 2 2024, 10:12:12) [MSC v.1938 64 bit (AMD64)]
Type-checker version and settings:
ms-python.vscode-pylance 2025.2.103
Additional typing packages.
No response
Describe the issue:
E.g.
resizeis using...as a default value instead ofFalse.Not sure if default arguments have any value for running static type check on the code, but having them at hand is very convenient when reading/writing code.
numpy/numpy/__init__.pyi
Lines 2206 to 2209 in 9a2b8b4
Reproduce the code example:
Python and NumPy Versions:
2.2.3
3.11.9 (tags/v3.11.9:de54cf5, Apr 2 2024, 10:12:12) [MSC v.1938 64 bit (AMD64)]
Type-checker version and settings:
ms-python.vscode-pylance 2025.2.103
Additional typing packages.
No response