提交 8aefe5be authored 作者: James Bergstra's avatar James Bergstra

Added length assert before zip statement in FunctionMaker. It was never a

problem, but ... it could have been?
上级 0a5ec006
......@@ -756,6 +756,7 @@ class FunctionMaker(object):
"or one of %s" % mode_module.predefined_linkers.keys())
#the 'no_borrow' outputs are the ones for which that we can't return the internal storage pointer.
assert len(env.outputs) == len(outputs+additional_outputs)
no_borrow = [output for output, spec in zip(env.outputs, outputs+additional_outputs) if not spec.borrow]
if no_borrow:
self.linker = linker.accept(env, no_recycling = infer_reuse_pattern(env, no_borrow))
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论