MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / replace

Method replace

tools/python-3.11.9-amd64/Lib/inspect.py:2738–2754  ·  view source on GitHub ↗

Creates a customized copy of the Parameter.

(self, *, name=_void, kind=_void,
                annotation=_void, default=_void)

Source from the content-addressed store, hash-verified

2736 return self._kind
2737
2738 def replace(self, *, name=_void, kind=_void,
2739 annotation=_void, default=_void):
2740 """Creates a customized copy of the Parameter."""
2741
2742 if name is _void:
2743 name = self._name
2744
2745 if kind is _void:
2746 kind = self._kind
2747
2748 if annotation is _void:
2749 annotation = self._annotation
2750
2751 if default is _void:
2752 default = self._default
2753
2754 return type(self)(name, kind, default=default, annotation=annotation)
2755
2756 def __str__(self):
2757 kind = self.kind

Callers 4

_signature_get_partialFunction · 0.45
_signature_bound_methodFunction · 0.45
_signature_fromstrFunction · 0.45
_signature_from_callableFunction · 0.45

Calls 1

typeClass · 0.50

Tested by

no test coverage detected