Commit 0b6056bd authored by Xavier Thompson's avatar Xavier Thompson

Fix crash in cypclass lock analysis when passing NULL as cypclass argument

parent 99a533ea
......@@ -731,7 +731,7 @@ class CypclassLockTransform(Visitor.EnvTransform):
formal_nargs = len(func_type.args)
actual_nargs = len(node.args)
for i, formal_arg, actual_arg in zip(range(actual_nargs), func_type.args, node.args):
if formal_arg.type.is_cyp_class:
if formal_arg.type.is_cyp_class and actual_arg.type.is_cyp_class:
node.args[i] = self.lockcheck_written_or_read(actual_arg, reading=formal_arg.type.is_const)
with self.accesscontext(reading=True):
self.visitchildren(node)
......
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