Commit 1311005a authored by gsamain's avatar gsamain Committed by Xavier Thompson

Make new statement on cypclass call default constructor

parent 7b490853
......@@ -5991,6 +5991,8 @@ class SimpleCallNode(CallNode):
max_nargs = len(func_type.args)
expected_nargs = max_nargs - func_type.optional_arg_count
actual_nargs = len(self.args)
if self.type.is_cyp_class and isinstance(self.function, NewExprNode):
return "%s()" % self.function.result()
for formal_arg, actual_arg in args[:expected_nargs]:
arg_code = actual_arg.move_result_rhs_as(formal_arg.type)
arg_list_code.append(arg_code)
......
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