MCPcopy Index your code
hub / github.com/python/mypy / test_set_attr

Method test_set_attr

mypyc/test/test_emitfunc.py:530–539  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

528 )
529
530 def test_set_attr(self) -> None:
531 self.assert_emit(
532 SetAttr(self.r, "y", self.m, 1),
533 """if (((mod___AObject *)cpy_r_r)->_y != CPY_INT_TAG) {
534 CPyTagged_DECREF(((mod___AObject *)cpy_r_r)->_y);
535 }
536 ((mod___AObject *)cpy_r_r)->_y = cpy_r_m;
537 cpy_r_r0 = 1;
538 """,
539 )
540
541 def test_set_attr_non_refcounted(self) -> None:
542 self.assert_emit(

Callers

nothing calls this directly

Calls 2

assert_emitMethod · 0.95
SetAttrClass · 0.90

Tested by

no test coverage detected