| Total Complexity | 1 |
| Total Lines | 13 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | """Functions for representing placeholders, which are used in abstract matchers.""" |
||
| 2 | |||
| 3 | import typing |
||
| 4 | |||
| 5 | T_co = typing.TypeVar("T_co", covariant=True) # pylint: disable=invalid-name |
||
| 6 | |||
| 7 | |||
| 8 | class Placeholder(typing.Generic[T_co]): |
||
| 9 | """Class for representing placeholder functions.""" |
||
| 10 | |||
| 11 | def __init__(self, func: typing.Callable[[type], T_co]): |
||
| 12 | self.func = func |
||
| 13 |