We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2295ecc commit f8c0d17Copy full SHA for f8c0d17
mypyc/transform/log_trace.py
@@ -15,7 +15,9 @@
15
Call,
16
CallC,
17
CString,
18
+ DecRef,
19
GetAttr,
20
+ IncRef,
21
LoadLiteral,
22
LoadStatic,
23
Op,
@@ -96,6 +98,12 @@ def visit_box(self, op: Box) -> Value | None:
96
98
def visit_unbox(self, op: Unbox) -> Value | None:
97
99
return self.log(op, "unbox", str(op.type))
100
101
+ def visit_inc_ref(self, op: IncRef) -> Value | None:
102
+ return self.log(op, "inc_ref", str(op.src.type))
103
+
104
+ def visit_dec_ref(self, op: DecRef) -> Value | None:
105
+ return self.log(op, "dec_ref", str(op.src.type))
106
107
def log(self, op: Op, name: str, details: str) -> Value:
108
if op.line >= 0:
109
line_str = str(op.line)
0 commit comments