Commit b52943ec authored by Robert Bradshaw's avatar Robert Bradshaw

merge

parents 07327449 ba920e46
......@@ -961,7 +961,6 @@ class FuncDefNode(StatNode, BlockNode):
for arg in self.args:
if arg.default:
if arg.is_generic:
if not hasattr(arg, 'default_entry'):
arg.default.analyse_types(env)
arg.default = arg.default.coerce_to(arg.type, genv)
arg.default.allocate_temps(genv)
......@@ -1352,9 +1351,11 @@ class CFuncDefNode(FuncDefNode):
error(self.pos, "Function declared nogil has Python locals or temporaries")
def analyse_expressions(self, env):
self.analyse_default_values(env)
if self.py_func is not None:
# this will also analyse the default values
self.py_func.analyse_expressions(env)
else:
self.analyse_default_values(env)
def generate_function_header(self, code, with_pymethdef, with_opt_args = 1, with_dispatch = 1, cname = None):
arg_decls = []
......
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