File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ API reference
55 :members:
66 :undoc-members:
77 :show-inheritance:
8- :exclude-members: Registry, World, Entity
8+ :exclude-members: Registry, World, Entity, IsA
99
1010.. automodule :: tcod.ecs.registry
1111 :members:
Original file line number Diff line number Diff line change 22
33from __future__ import annotations
44
5+ from typing_extensions import Never
6+
57
68class _IgnoreSetState (type ):
79 def __setstate__ (cls , _state : object ) -> None :
@@ -11,9 +13,8 @@ def __setstate__(cls, _state: object) -> None:
1113class IsA (metaclass = _IgnoreSetState ):
1214 """The default is-a relationship tag used for entity inheritance."""
1315
14- def __new__ (cls : type [IsA ], * _args : object ) -> type [IsA ]: # type: ignore[misc]
15- """Return own type instead of instance, for outdated sentinel-value pickle data."""
16- return cls
16+ def __new__ (cls : type [IsA ], * _ : object ) -> Never : # noqa: D102
17+ return cls # Return own type instead of instance, for outdated sentinel-value pickle data.
1718
1819
1920_sentinel_IsA = IsA # Compatibility with sentinel-value, deprecated since 5.4 # noqa: N816
You can’t perform that action at this time.
0 commit comments