3855
3855
if (!(dim <= vala_array_type_get_rank (array_type))) {
3858
vala_ccode_struct_add_field (data, "gint", _tmp16_ = vala_ccode_base_module_get_array_length_cname (self, _tmp15_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param)), dim), NULL);
3858
vala_ccode_struct_add_field (data, "gint", _tmp15_ = vala_ccode_base_module_get_parameter_array_length_cname (self, param, dim), NULL);
3860
3859
_g_free0 (_tmp15_);
3861
vala_ccode_block_add_statement (cblock, (ValaCCodeNode*) (_tmp26_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) (_tmp25_ = vala_ccode_assignment_new ((ValaCCodeExpression*) (_tmp21_ = vala_ccode_member_access_new_pointer (_tmp18_ = vala_ccode_base_module_get_variable_cexpression (self, _tmp17_ = g_strdup_printf ("_data%d_", block_id)), _tmp20_ = vala_ccode_base_module_get_array_length_cname (self, _tmp19_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param)), dim))), (ValaCCodeExpression*) (_tmp24_ = vala_ccode_identifier_new (_tmp23_ = vala_ccode_base_module_get_array_length_cname (self, _tmp22_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param)), dim))), VALA_CCODE_ASSIGNMENT_OPERATOR_SIMPLE)))));
3862
_vala_ccode_node_unref0 (_tmp26_);
3863
_vala_ccode_node_unref0 (_tmp25_);
3864
_vala_ccode_node_unref0 (_tmp24_);
3860
vala_ccode_block_add_statement (cblock, (ValaCCodeNode*) (_tmp23_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) (_tmp22_ = vala_ccode_assignment_new ((ValaCCodeExpression*) (_tmp19_ = vala_ccode_member_access_new_pointer (_tmp17_ = vala_ccode_base_module_get_variable_cexpression (self, _tmp16_ = g_strdup_printf ("_data%d_", block_id)), _tmp18_ = vala_ccode_base_module_get_parameter_array_length_cname (self, param, dim))), (ValaCCodeExpression*) (_tmp21_ = vala_ccode_identifier_new (_tmp20_ = vala_ccode_base_module_get_parameter_array_length_cname (self, param, dim))), VALA_CCODE_ASSIGNMENT_OPERATOR_SIMPLE)))));
3861
_vala_ccode_node_unref0 (_tmp23_);
3862
_vala_ccode_node_unref0 (_tmp22_);
3867
3863
_vala_ccode_node_unref0 (_tmp21_);
3868
3864
_g_free0 (_tmp20_);
3870
_vala_ccode_node_unref0 (_tmp18_);
3865
_vala_ccode_node_unref0 (_tmp19_);
3867
_vala_ccode_node_unref0 (_tmp17_);
3875
3872
_vala_code_node_unref0 (array_type);
3877
3874
if (VALA_IS_DELEGATE_TYPE (vala_variable_get_variable_type ((ValaVariable*) param))) {
3878
ValaCCodeExpression* _tmp27_;
3881
ValaCCodeExpression* _tmp30_;
3881
ValaCCodeMemberAccess* _tmp30_;
3884
ValaCCodeMemberAccess* _tmp33_;
3887
ValaCCodeIdentifier* _tmp36_;
3888
ValaCCodeAssignment* _tmp37_;
3889
ValaCCodeExpressionStatement* _tmp38_;
3890
vala_ccode_struct_add_field (data, "gpointer", _tmp28_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp27_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))), NULL);
3884
ValaCCodeIdentifier* _tmp33_;
3885
ValaCCodeAssignment* _tmp34_;
3886
ValaCCodeExpressionStatement* _tmp35_;
3887
vala_ccode_struct_add_field (data, "gpointer", _tmp25_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp24_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))), NULL);
3890
vala_ccode_block_add_statement (cblock, (ValaCCodeNode*) (_tmp35_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) (_tmp34_ = vala_ccode_assignment_new ((ValaCCodeExpression*) (_tmp30_ = vala_ccode_member_access_new_pointer (_tmp27_ = vala_ccode_base_module_get_variable_cexpression (self, _tmp26_ = g_strdup_printf ("_data%d_", block_id)), _tmp29_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp28_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))))), (ValaCCodeExpression*) (_tmp33_ = vala_ccode_identifier_new (_tmp32_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp31_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))))), VALA_CCODE_ASSIGNMENT_OPERATOR_SIMPLE)))));
3891
_vala_ccode_node_unref0 (_tmp35_);
3892
_vala_ccode_node_unref0 (_tmp34_);
3893
_vala_ccode_node_unref0 (_tmp33_);
3896
_vala_ccode_node_unref0 (_tmp30_);
3891
3898
_g_free0 (_tmp28_);
3893
vala_ccode_block_add_statement (cblock, (ValaCCodeNode*) (_tmp38_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) (_tmp37_ = vala_ccode_assignment_new ((ValaCCodeExpression*) (_tmp33_ = vala_ccode_member_access_new_pointer (_tmp30_ = vala_ccode_base_module_get_variable_cexpression (self, _tmp29_ = g_strdup_printf ("_data%d_", block_id)), _tmp32_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp31_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))))), (ValaCCodeExpression*) (_tmp36_ = vala_ccode_identifier_new (_tmp35_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp34_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))))), VALA_CCODE_ASSIGNMENT_OPERATOR_SIMPLE)))));
3894
_vala_ccode_node_unref0 (_tmp38_);
3895
_vala_ccode_node_unref0 (_tmp37_);
3896
_vala_ccode_node_unref0 (_tmp36_);
3899
_vala_ccode_node_unref0 (_tmp33_);
3902
_vala_ccode_node_unref0 (_tmp30_);
3899
_vala_ccode_node_unref0 (_tmp27_);
3904
3901
if (vala_data_type_get_value_owned (vala_variable_get_variable_type ((ValaVariable*) param))) {
3905
ValaCCodeExpression* _tmp39_;
3908
ValaCCodeExpression* _tmp42_;
3908
ValaCCodeMemberAccess* _tmp42_;
3911
ValaCCodeMemberAccess* _tmp45_;
3914
ValaCCodeIdentifier* _tmp48_;
3915
ValaCCodeAssignment* _tmp49_;
3916
ValaCCodeExpressionStatement* _tmp50_;
3917
vala_ccode_struct_add_field (data, "GDestroyNotify", _tmp40_ = vala_ccode_base_module_get_delegate_target_destroy_notify_cname (self, _tmp39_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))), NULL);
3911
ValaCCodeIdentifier* _tmp45_;
3912
ValaCCodeAssignment* _tmp46_;
3913
ValaCCodeExpressionStatement* _tmp47_;
3914
vala_ccode_struct_add_field (data, "GDestroyNotify", _tmp37_ = vala_ccode_base_module_get_delegate_target_destroy_notify_cname (self, _tmp36_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))), NULL);
3917
vala_ccode_block_add_statement (cblock, (ValaCCodeNode*) (_tmp47_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) (_tmp46_ = vala_ccode_assignment_new ((ValaCCodeExpression*) (_tmp42_ = vala_ccode_member_access_new_pointer (_tmp39_ = vala_ccode_base_module_get_variable_cexpression (self, _tmp38_ = g_strdup_printf ("_data%d_", block_id)), _tmp41_ = vala_ccode_base_module_get_delegate_target_destroy_notify_cname (self, _tmp40_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))))), (ValaCCodeExpression*) (_tmp45_ = vala_ccode_identifier_new (_tmp44_ = vala_ccode_base_module_get_delegate_target_destroy_notify_cname (self, _tmp43_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))))), VALA_CCODE_ASSIGNMENT_OPERATOR_SIMPLE)))));
3918
_vala_ccode_node_unref0 (_tmp47_);
3919
_vala_ccode_node_unref0 (_tmp46_);
3920
_vala_ccode_node_unref0 (_tmp45_);
3923
_vala_ccode_node_unref0 (_tmp42_);
3918
3925
_g_free0 (_tmp40_);
3920
vala_ccode_block_add_statement (cblock, (ValaCCodeNode*) (_tmp50_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) (_tmp49_ = vala_ccode_assignment_new ((ValaCCodeExpression*) (_tmp45_ = vala_ccode_member_access_new_pointer (_tmp42_ = vala_ccode_base_module_get_variable_cexpression (self, _tmp41_ = g_strdup_printf ("_data%d_", block_id)), _tmp44_ = vala_ccode_base_module_get_delegate_target_destroy_notify_cname (self, _tmp43_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))))), (ValaCCodeExpression*) (_tmp48_ = vala_ccode_identifier_new (_tmp47_ = vala_ccode_base_module_get_delegate_target_destroy_notify_cname (self, _tmp46_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param))))), VALA_CCODE_ASSIGNMENT_OPERATOR_SIMPLE)))));
3921
_vala_ccode_node_unref0 (_tmp50_);
3922
_vala_ccode_node_unref0 (_tmp49_);
3923
_vala_ccode_node_unref0 (_tmp48_);
3926
_vala_ccode_node_unref0 (_tmp45_);
3929
_vala_ccode_node_unref0 (_tmp42_);
3926
_vala_ccode_node_unref0 (_tmp39_);
3934
3931
if (vala_ccode_base_module_requires_destroy (self, param_type)) {
3935
_tmp51_ = !is_unowned_delegate;
3932
_tmp48_ = !is_unowned_delegate;
3940
3937
gboolean old_coroutine;
3941
3938
ValaMemberAccess* ma;
3942
ValaDataType* _tmp52_;
3944
ValaCCodeIdentifier* _tmp54_;
3946
ValaCCodeMemberAccess* _tmp56_;
3947
ValaCCodeExpression* _tmp57_;
3948
ValaCCodeExpressionStatement* _tmp58_;
3939
ValaDataType* _tmp49_;
3941
ValaCCodeIdentifier* _tmp51_;
3943
ValaCCodeMemberAccess* _tmp53_;
3944
ValaCCodeExpression* _tmp54_;
3945
ValaCCodeExpressionStatement* _tmp55_;
3949
3946
old_coroutine = FALSE;
3950
3947
if (vala_ccode_base_module_get_current_method (self) != NULL) {
3951
3948
old_coroutine = vala_method_get_coroutine (vala_ccode_base_module_get_current_method (self));
3954
3951
ma = vala_member_access_new_simple (vala_symbol_get_name ((ValaSymbol*) param), NULL);
3955
3952
vala_expression_set_symbol_reference ((ValaExpression*) ma, (ValaSymbol*) param);
3956
vala_expression_set_value_type ((ValaExpression*) ma, _tmp52_ = vala_data_type_copy (param_type));
3957
_vala_code_node_unref0 (_tmp52_);
3958
vala_ccode_block_add_statement (free_block, (ValaCCodeNode*) (_tmp58_ = vala_ccode_expression_statement_new (_tmp57_ = vala_ccode_base_module_get_unref_expression (self, (ValaCCodeExpression*) (_tmp56_ = vala_ccode_member_access_new_pointer ((ValaCCodeExpression*) (_tmp54_ = vala_ccode_identifier_new (_tmp53_ = g_strdup_printf ("_data%d_", block_id))), _tmp55_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param)))), vala_variable_get_variable_type ((ValaVariable*) param), (ValaExpression*) ma, FALSE))));
3959
_vala_ccode_node_unref0 (_tmp58_);
3960
_vala_ccode_node_unref0 (_tmp57_);
3961
_vala_ccode_node_unref0 (_tmp56_);
3953
vala_expression_set_value_type ((ValaExpression*) ma, _tmp49_ = vala_data_type_copy (param_type));
3954
_vala_code_node_unref0 (_tmp49_);
3955
vala_ccode_block_add_statement (free_block, (ValaCCodeNode*) (_tmp55_ = vala_ccode_expression_statement_new (_tmp54_ = vala_ccode_base_module_get_unref_expression (self, (ValaCCodeExpression*) (_tmp53_ = vala_ccode_member_access_new_pointer ((ValaCCodeExpression*) (_tmp51_ = vala_ccode_identifier_new (_tmp50_ = g_strdup_printf ("_data%d_", block_id))), _tmp52_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param)))), vala_variable_get_variable_type ((ValaVariable*) param), (ValaExpression*) ma, FALSE))));
3956
_vala_ccode_node_unref0 (_tmp55_);
3963
3957
_vala_ccode_node_unref0 (_tmp54_);
3958
_vala_ccode_node_unref0 (_tmp53_);
3960
_vala_ccode_node_unref0 (_tmp51_);
3965
3962
if (old_coroutine) {
3966
3963
vala_method_set_coroutine (vala_ccode_base_module_get_current_method (self), TRUE);