mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-05-17 13:59:45 +08:00
Update Unused parameters in stubs/ (#9704)
* Update _Unused TypeAlias * Update `object | None` params * Replace unused `object` parameters with `Unused` alias
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
from _typeshed import Incomplete
|
||||
from _typeshed import Incomplete, Unused
|
||||
from abc import abstractmethod
|
||||
from collections.abc import Iterable, Iterator
|
||||
from typing import SupportsInt, overload
|
||||
@@ -133,7 +133,7 @@ class IPNetwork(BaseIP, IPListMixin):
|
||||
def previous(self, step: int = ...) -> Self: ...
|
||||
def next(self, step: int = ...) -> Self: ...
|
||||
def supernet(self, prefixlen: int = ...) -> list[IPNetwork]: ...
|
||||
def subnet(self, prefixlen: int, count: int | None = ..., fmt: object | None = ...) -> Iterator[Self]: ...
|
||||
def subnet(self, prefixlen: int, count: int | None = ..., fmt: Unused = None) -> Iterator[Self]: ...
|
||||
def iter_hosts(self) -> Iterator[IPAddress]: ...
|
||||
|
||||
class IPRange(BaseIP, IPListMixin):
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
from _typeshed import Unused
|
||||
from collections.abc import Iterable, Sequence
|
||||
from socket import AddressFamily
|
||||
from typing_extensions import Literal
|
||||
@@ -22,7 +23,7 @@ hostmask_to_prefix: dict[int, int]
|
||||
|
||||
def valid_str(addr: str, flags: int = ...) -> bool: ...
|
||||
def str_to_int(addr: str, flags: int = ...) -> int: ...
|
||||
def int_to_str(int_val: int, dialect: object | None = ...) -> str: ...
|
||||
def int_to_str(int_val: int, dialect: Unused = None) -> str: ...
|
||||
def int_to_arpa(int_val: int) -> str: ...
|
||||
def int_to_packed(int_val: int) -> bytes: ...
|
||||
def packed_to_int(packed_int: bytes) -> int: ...
|
||||
|
||||
Reference in New Issue
Block a user