Commit a6377482 authored by gsamain's avatar gsamain Committed by Xavier Thompson

Properly decref self when deallocating acthon message

parent b9f65a4d
......@@ -1518,6 +1518,7 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode):
# Destructor
code.putln("virtual ~%s() {" % class_name)
code.putln("Cy_DECREF(this->%s);" % target_object_cname)
put_cypclass_op_on_narg_optarg(lambda _: "Cy_DECREF", reified_function_entry.type, Naming.optional_args_cname, code)
if opt_arg_count:
code.putln("free(this->%s);" % Naming.optional_args_cname)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment