From fc147b68a47ade275040d098110306f023b21a8c Mon Sep 17 00:00:00 2001 From: Robert Bradshaw Date: Sat, 2 Aug 2008 15:04:53 -0700 Subject: [PATCH] Get rid of unused argument warning, noticed by Ondrej Certik, fix by Carl Witty --- Cython/Compiler/Nodes.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Cython/Compiler/Nodes.py b/Cython/Compiler/Nodes.py index 9911ae4b..1f857e84 100644 --- a/Cython/Compiler/Nodes.py +++ b/Cython/Compiler/Nodes.py @@ -1543,6 +1543,10 @@ class DefNode(FuncDefNode): def generate_argument_parsing_code(self, env, code): # Generate PyArg_ParseTuple call for generic # arguments, if any. + if self.entry.signature.has_dummy_arg: + # get rid of unused argument warning + code.putln("%s = %s;" % (Naming.self_cname, Naming.self_cname)) + old_error_label = code.new_error_label() our_error_label = code.error_label end_label = code.new_label() -- 2.26.2