MCPcopy Create free account
hub / github.com/RustPython/RustPython / _paramspec_subst

Function _paramspec_subst

Lib/typing.py:1087–1093  ·  view source on GitHub ↗
(self, arg)

Source from the content-addressed store, hash-verified

1085
1086
1087def _paramspec_subst(self, arg):
1088 if isinstance(arg, (list, tuple)):
1089 arg = tuple(_type_check(a, "Expected a type.") for a in arg)
1090 elif not _is_param_expr(arg):
1091 raise TypeError(f"Expected a list of types, an ellipsis, "
1092 f"ParamSpec, or Concatenate. Got {arg}")
1093 return arg
1094
1095
1096def _paramspec_prepare_subst(self, alias, args):

Callers

nothing calls this directly

Calls 3

isinstanceFunction · 0.85
_type_checkFunction · 0.85
_is_param_exprFunction · 0.70

Tested by

no test coverage detected