mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-15 16:27:08 +08:00
Create stubs for toposort (#6048)
This commit is contained in:
@@ -60,6 +60,7 @@
|
||||
"stubs/simplejson",
|
||||
"stubs/slumber",
|
||||
"stubs/stripe",
|
||||
"stubs/toposort",
|
||||
"stubs/ttkthemes",
|
||||
"stubs/vobject",
|
||||
"stubs/waitress",
|
||||
|
||||
1
stubs/toposort/METADATA.toml
Normal file
1
stubs/toposort/METADATA.toml
Normal file
@@ -0,0 +1 @@
|
||||
version = "1.6"
|
||||
10
stubs/toposort/toposort.pyi
Normal file
10
stubs/toposort/toposort.pyi
Normal file
@@ -0,0 +1,10 @@
|
||||
from typing import Any, Iterator, TypeVar
|
||||
|
||||
_T = TypeVar("_T")
|
||||
|
||||
class CircularDependencyError(ValueError):
|
||||
data: dict[Any, set[Any]]
|
||||
def __init__(self, data: dict[Any, set[Any]]) -> None: ...
|
||||
|
||||
def toposort(data: dict[_T, set[_T]]) -> Iterator[set[_T]]: ...
|
||||
def toposort_flatten(data: dict[_T, set[_T]], sort: bool = ...) -> list[_T]: ...
|
||||
Reference in New Issue
Block a user