MCPcopy Index your code
hub / github.com/RustPython/RustPython / store_class_fields

Function store_class_fields

extra_tests/custom_text_test_runner.py:130–134  ·  view source on GitHub ↗

Store the passed in class fields in self

(class_ref, args_passed)

Source from the content-addressed store, hash-verified

128
129
130def store_class_fields(class_ref, args_passed):
131 """Store the passed in class fields in self"""
132 params = get_function_args(class_ref.__init__)
133 for p in params:
134 setattr(class_ref, p, args_passed[p])
135
136
137def sum_dict_key(d, key, cast_type=None):

Callers 2

__init__Method · 0.85
__init__Method · 0.85

Calls 2

get_function_argsFunction · 0.85
setattrFunction · 0.85

Tested by

no test coverage detected