3011
3023
if (vala_property_get_is_abstract (prop)) {
3026
_tmp6_ = vala_property_get_is_virtual (prop);
3014
_tmp5_ = vala_property_get_is_virtual (prop);
3019
gboolean _tmp6_ = FALSE;
3031
gboolean _tmp7_ = FALSE;
3020
3032
if (vala_property_get_base_property (prop) == NULL) {
3021
_tmp6_ = vala_property_get_base_interface_property (prop) == NULL;
3033
_tmp7_ = vala_property_get_base_interface_property (prop) == NULL;
3028
gboolean _tmp7_ = FALSE;
3040
gboolean _tmp8_ = FALSE;
3029
3041
vala_ccode_base_module_generate_property_accessor_declaration (self, acc, self->source_declarations);
3030
3042
if (vala_property_accessor_get_readable (acc)) {
3033
_tmp7_ = vala_property_accessor_get_writable (acc);
3045
_tmp8_ = vala_property_accessor_get_writable (acc);
3036
gboolean _tmp8_ = FALSE;
3037
gboolean _tmp10_ = FALSE;
3048
gboolean _tmp9_ = FALSE;
3049
gboolean _tmp11_ = FALSE;
3038
3050
if (!vala_symbol_is_internal_symbol ((ValaSymbol*) prop)) {
3039
gboolean _tmp9_ = FALSE;
3051
gboolean _tmp10_ = FALSE;
3040
3052
if (vala_symbol_get_access ((ValaSymbol*) acc) == VALA_SYMBOL_ACCESSIBILITY_PUBLIC) {
3043
_tmp9_ = vala_symbol_get_access ((ValaSymbol*) acc) == VALA_SYMBOL_ACCESSIBILITY_PROTECTED;
3055
_tmp10_ = vala_symbol_get_access ((ValaSymbol*) acc) == VALA_SYMBOL_ACCESSIBILITY_PROTECTED;
3050
3062
vala_ccode_base_module_generate_property_accessor_declaration (self, acc, self->header_declarations);
3052
3064
if (!vala_symbol_is_private_symbol ((ValaSymbol*) prop)) {
3053
_tmp10_ = vala_symbol_get_access ((ValaSymbol*) acc) != VALA_SYMBOL_ACCESSIBILITY_PRIVATE;
3065
_tmp11_ = vala_symbol_get_access ((ValaSymbol*) acc) != VALA_SYMBOL_ACCESSIBILITY_PRIVATE;
3058
3070
vala_ccode_base_module_generate_property_accessor_declaration (self, acc, self->internal_header_declarations);
3062
3074
this_type = vala_ccode_base_module_get_data_type_for_symbol (t);
3063
cselfparam = (_tmp12_ = vala_ccode_formal_parameter_new ("self", _tmp11_ = vala_data_type_get_cname (this_type)), _g_free0 (_tmp11_), _tmp12_);
3075
cselfparam = (_tmp13_ = vala_ccode_formal_parameter_new ("self", _tmp12_ = vala_data_type_get_cname (this_type)), _g_free0 (_tmp12_), _tmp13_);
3064
3076
if (VALA_IS_STRUCT (t)) {
3066
vala_ccode_formal_parameter_set_type_name (cselfparam, _tmp13_ = g_strconcat (vala_ccode_formal_parameter_get_type_name (cselfparam), "*", NULL));
3078
vala_ccode_formal_parameter_set_type_name (cselfparam, _tmp14_ = g_strconcat (vala_ccode_formal_parameter_get_type_name (cselfparam), "*", NULL));
3069
3081
cvalueparam = NULL;
3070
3082
if (returns_real_struct) {
3071
ValaCCodeFormalParameter* _tmp16_;
3083
ValaCCodeFormalParameter* _tmp17_;
3074
cvalueparam = (_tmp16_ = vala_ccode_formal_parameter_new ("result", _tmp15_ = g_strconcat (_tmp14_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc)), "*", NULL)), _vala_ccode_node_unref0 (cvalueparam), _tmp16_);
3086
cvalueparam = (_tmp17_ = vala_ccode_formal_parameter_new ("result", _tmp16_ = g_strconcat (_tmp15_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc)), "*", NULL)), _vala_ccode_node_unref0 (cvalueparam), _tmp17_);
3075
3088
_g_free0 (_tmp15_);
3078
gboolean _tmp17_ = FALSE;
3090
gboolean _tmp18_ = FALSE;
3079
3091
if (!vala_property_accessor_get_readable (acc)) {
3080
_tmp17_ = vala_data_type_is_real_non_null_struct_type (vala_property_get_property_type (prop));
3092
_tmp18_ = vala_data_type_is_real_non_null_struct_type (vala_property_get_property_type (prop));
3085
ValaCCodeFormalParameter* _tmp20_;
3097
ValaCCodeFormalParameter* _tmp21_;
3088
cvalueparam = (_tmp20_ = vala_ccode_formal_parameter_new ("value", _tmp19_ = g_strconcat (_tmp18_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc)), "*", NULL)), _vala_ccode_node_unref0 (cvalueparam), _tmp20_);
3100
cvalueparam = (_tmp21_ = vala_ccode_formal_parameter_new ("value", _tmp20_ = g_strconcat (_tmp19_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc)), "*", NULL)), _vala_ccode_node_unref0 (cvalueparam), _tmp21_);
3089
3102
_g_free0 (_tmp19_);
3092
ValaCCodeFormalParameter* _tmp22_;
3094
cvalueparam = (_tmp22_ = vala_ccode_formal_parameter_new ("value", _tmp21_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc))), _vala_ccode_node_unref0 (cvalueparam), _tmp22_);
3104
ValaCCodeFormalParameter* _tmp23_;
3106
cvalueparam = (_tmp23_ = vala_ccode_formal_parameter_new ("value", _tmp22_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc))), _vala_ccode_node_unref0 (cvalueparam), _tmp23_);
3098
3110
if (vala_property_get_is_abstract (prop)) {
3101
_tmp23_ = vala_property_get_is_virtual (prop);
3113
_tmp24_ = vala_property_get_is_virtual (prop);
3104
gboolean _tmp24_ = FALSE;
3105
gboolean _tmp30_ = FALSE;
3116
gboolean _tmp25_ = FALSE;
3106
3117
gboolean _tmp31_ = FALSE;
3107
gboolean _tmp42_ = FALSE;
3118
gboolean _tmp32_ = FALSE;
3108
3119
gboolean _tmp43_ = FALSE;
3120
gboolean _tmp44_ = FALSE;
3109
3121
ValaCCodeBlock* block;
3110
3122
ValaCCodeFunctionCall* vcast;
3111
ValaCCodeIdentifier* _tmp53_;
3123
ValaCCodeIdentifier* _tmp54_;
3112
3124
if (vala_property_accessor_get_readable (acc)) {
3113
_tmp24_ = !returns_real_struct;
3125
_tmp25_ = !returns_real_struct;
3118
ValaCCodeFunction* _tmp27_;
3130
ValaCCodeFunction* _tmp28_;
3121
self->function = (_tmp27_ = vala_ccode_function_new (_tmp25_ = vala_property_accessor_get_cname (acc), _tmp26_ = vala_data_type_get_cname (vala_ccode_base_module_get_current_return_type (self))), _vala_ccode_node_unref0 (self->function), _tmp27_);
3133
self->function = (_tmp28_ = vala_ccode_function_new (_tmp26_ = vala_property_accessor_get_cname (acc), _tmp27_ = vala_data_type_get_cname (vala_ccode_base_module_get_current_return_type (self))), _vala_ccode_node_unref0 (self->function), _tmp28_);
3122
3135
_g_free0 (_tmp26_);
3125
ValaCCodeFunction* _tmp29_;
3127
self->function = (_tmp29_ = vala_ccode_function_new (_tmp28_ = vala_property_accessor_get_cname (acc), "void"), _vala_ccode_node_unref0 (self->function), _tmp29_);
3137
ValaCCodeFunction* _tmp30_;
3139
self->function = (_tmp30_ = vala_ccode_function_new (_tmp29_ = vala_property_accessor_get_cname (acc), "void"), _vala_ccode_node_unref0 (self->function), _tmp30_);
3130
3142
vala_ccode_function_add_parameter (self->function, cselfparam);
3131
3143
if (vala_property_accessor_get_writable (acc)) {
3146
_tmp32_ = vala_property_accessor_get_construction (acc);
3132
3149
_tmp31_ = TRUE;
3134
_tmp31_ = vala_property_accessor_get_construction (acc);
3151
_tmp31_ = returns_real_struct;
3139
_tmp30_ = returns_real_struct;
3142
3154
vala_ccode_function_add_parameter (self->function, cvalueparam);
3144
3156
if (VALA_IS_ARRAY_TYPE (vala_property_accessor_get_value_type (acc))) {
3147
3159
array_type = _vala_code_node_ref0 (VALA_ARRAY_TYPE (vala_property_accessor_get_value_type (acc)));
3148
3160
length_ctype = g_strdup ("int");
3149
3161
if (vala_property_accessor_get_readable (acc)) {
3151
length_ctype = (_tmp32_ = g_strdup ("int*"), _g_free0 (length_ctype), _tmp32_);
3163
length_ctype = (_tmp33_ = g_strdup ("int*"), _g_free0 (length_ctype), _tmp33_);
3160
const char* _tmp34_;
3161
ValaCCodeFormalParameter* _tmp36_;
3172
const char* _tmp35_;
3173
ValaCCodeFormalParameter* _tmp37_;
3167
3179
if (!(dim <= vala_array_type_get_rank (array_type))) {
3171
3183
if (vala_property_accessor_get_readable (acc)) {
3176
vala_ccode_function_add_parameter (self->function, _tmp36_ = vala_ccode_formal_parameter_new (_tmp35_ = vala_ccode_module_get_array_length_cname (vala_ccode_module_get_head ((ValaCCodeModule*) self), _tmp34_, dim), length_ctype));
3177
_vala_ccode_node_unref0 (_tmp36_);
3188
vala_ccode_function_add_parameter (self->function, _tmp37_ = vala_ccode_formal_parameter_new (_tmp36_ = vala_ccode_module_get_array_length_cname (vala_ccode_module_get_head ((ValaCCodeModule*) self), _tmp35_, dim), length_ctype));
3189
_vala_ccode_node_unref0 (_tmp37_);
3182
3194
_g_free0 (length_ctype);
3183
3195
_vala_code_node_unref0 (array_type);
3185
gboolean _tmp37_ = FALSE;
3197
gboolean _tmp38_ = FALSE;
3186
3198
if (VALA_IS_DELEGATE_TYPE (vala_property_accessor_get_value_type (acc))) {
3187
_tmp37_ = vala_delegate_get_has_target (vala_delegate_type_get_delegate_symbol (VALA_DELEGATE_TYPE (vala_property_accessor_get_value_type (acc))));
3199
_tmp38_ = vala_delegate_get_has_target (vala_delegate_type_get_delegate_symbol (VALA_DELEGATE_TYPE (vala_property_accessor_get_value_type (acc))));
3192
const char* _tmp38_;
3193
3204
const char* _tmp39_;
3194
ValaCCodeFormalParameter* _tmp41_;
3197
if (vala_property_accessor_get_readable (acc)) {
3205
const char* _tmp40_;
3206
ValaCCodeFormalParameter* _tmp42_;
3202
3208
_tmp39_ = NULL;
3203
3209
if (vala_property_accessor_get_readable (acc)) {
3204
_tmp39_ = "gpointer*";
3206
_tmp39_ = "gpointer";
3208
vala_ccode_function_add_parameter (self->function, _tmp41_ = vala_ccode_formal_parameter_new (_tmp40_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp38_), _tmp39_));
3209
_vala_ccode_node_unref0 (_tmp41_);
3215
if (vala_property_accessor_get_readable (acc)) {
3216
_tmp40_ = "gpointer*";
3218
_tmp40_ = "gpointer";
3220
vala_ccode_function_add_parameter (self->function, _tmp42_ = vala_ccode_formal_parameter_new (_tmp41_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp39_), _tmp40_));
3221
_vala_ccode_node_unref0 (_tmp42_);
3213
3225
if (vala_symbol_is_private_symbol ((ValaSymbol*) prop)) {
3228
gboolean _tmp45_ = FALSE;
3229
if (vala_property_accessor_get_readable (acc)) {
3232
_tmp45_ = vala_property_accessor_get_writable (acc);
3214
3237
_tmp43_ = TRUE;
3216
gboolean _tmp44_ = FALSE;
3217
if (vala_property_accessor_get_readable (acc)) {
3220
_tmp44_ = vala_property_accessor_get_writable (acc);
3239
_tmp43_ = vala_symbol_get_access ((ValaSymbol*) acc) == VALA_SYMBOL_ACCESSIBILITY_PRIVATE;
3227
_tmp42_ = vala_symbol_get_access ((ValaSymbol*) acc) == VALA_SYMBOL_ACCESSIBILITY_PRIVATE;
3230
3242
vala_ccode_function_set_modifiers (self->function, vala_ccode_function_get_modifiers (self->function) | VALA_CCODE_MODIFIERS_STATIC);
3232
3244
block = vala_ccode_block_new ();
3235
3247
if (VALA_IS_INTERFACE (vala_symbol_get_parent_symbol ((ValaSymbol*) prop))) {
3236
3248
ValaInterface* iface;
3237
ValaCCodeFunctionCall* _tmp48_;
3238
ValaCCodeIdentifier* _tmp47_;
3249
ValaCCodeFunctionCall* _tmp49_;
3250
ValaCCodeIdentifier* _tmp48_;
3241
3253
iface = _vala_code_node_ref0 (VALA_INTERFACE (vala_symbol_get_parent_symbol ((ValaSymbol*) prop)));
3242
vcast = (_tmp48_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp47_ = vala_ccode_identifier_new (_tmp46_ = g_strdup_printf ("%s_GET_INTERFACE", _tmp45_ = vala_typesymbol_get_upper_case_cname ((ValaTypeSymbol*) iface, NULL))))), _vala_ccode_node_unref0 (vcast), _tmp48_);
3243
_vala_ccode_node_unref0 (_tmp47_);
3254
vcast = (_tmp49_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp48_ = vala_ccode_identifier_new (_tmp47_ = g_strdup_printf ("%s_GET_INTERFACE", _tmp46_ = vala_typesymbol_get_upper_case_cname ((ValaTypeSymbol*) iface, NULL))))), _vala_ccode_node_unref0 (vcast), _tmp49_);
3255
_vala_ccode_node_unref0 (_tmp48_);
3244
3257
_g_free0 (_tmp46_);
3246
3258
_vala_code_node_unref0 (iface);
3249
ValaCCodeFunctionCall* _tmp52_;
3250
ValaCCodeIdentifier* _tmp51_;
3261
ValaCCodeFunctionCall* _tmp53_;
3262
ValaCCodeIdentifier* _tmp52_;
3253
3265
cl = _vala_code_node_ref0 (VALA_CLASS (vala_symbol_get_parent_symbol ((ValaSymbol*) prop)));
3254
vcast = (_tmp52_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp51_ = vala_ccode_identifier_new (_tmp50_ = g_strdup_printf ("%s_GET_CLASS", _tmp49_ = vala_typesymbol_get_upper_case_cname ((ValaTypeSymbol*) cl, NULL))))), _vala_ccode_node_unref0 (vcast), _tmp52_);
3255
_vala_ccode_node_unref0 (_tmp51_);
3266
vcast = (_tmp53_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp52_ = vala_ccode_identifier_new (_tmp51_ = g_strdup_printf ("%s_GET_CLASS", _tmp50_ = vala_typesymbol_get_upper_case_cname ((ValaTypeSymbol*) cl, NULL))))), _vala_ccode_node_unref0 (vcast), _tmp53_);
3267
_vala_ccode_node_unref0 (_tmp52_);
3256
3269
_g_free0 (_tmp50_);
3258
3270
_vala_code_node_unref0 (cl);
3260
vala_ccode_function_call_add_argument (vcast, (ValaCCodeExpression*) (_tmp53_ = vala_ccode_identifier_new ("self")));
3261
_vala_ccode_node_unref0 (_tmp53_);
3272
vala_ccode_function_call_add_argument (vcast, (ValaCCodeExpression*) (_tmp54_ = vala_ccode_identifier_new ("self")));
3273
_vala_ccode_node_unref0 (_tmp54_);
3262
3274
if (vala_property_accessor_get_readable (acc)) {
3263
ValaCCodeMemberAccess* _tmp55_;
3265
ValaCCodeFunctionCall* _tmp56_;
3275
ValaCCodeMemberAccess* _tmp56_;
3277
ValaCCodeFunctionCall* _tmp57_;
3266
3278
ValaCCodeFunctionCall* vcall;
3267
ValaCCodeIdentifier* _tmp57_;
3268
vcall = (_tmp56_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp55_ = vala_ccode_member_access_new_pointer ((ValaCCodeExpression*) vcast, _tmp54_ = g_strdup_printf ("get_%s", vala_symbol_get_name ((ValaSymbol*) prop))))), _vala_ccode_node_unref0 (_tmp55_), _g_free0 (_tmp54_), _tmp56_);
3269
vala_ccode_function_call_add_argument (vcall, (ValaCCodeExpression*) (_tmp57_ = vala_ccode_identifier_new ("self")));
3270
_vala_ccode_node_unref0 (_tmp57_);
3279
ValaCCodeIdentifier* _tmp58_;
3280
vcall = (_tmp57_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp56_ = vala_ccode_member_access_new_pointer ((ValaCCodeExpression*) vcast, _tmp55_ = g_strdup_printf ("get_%s", vala_symbol_get_name ((ValaSymbol*) prop))))), _vala_ccode_node_unref0 (_tmp56_), _g_free0 (_tmp55_), _tmp57_);
3281
vala_ccode_function_call_add_argument (vcall, (ValaCCodeExpression*) (_tmp58_ = vala_ccode_identifier_new ("self")));
3282
_vala_ccode_node_unref0 (_tmp58_);
3271
3283
if (returns_real_struct) {
3272
ValaCCodeIdentifier* _tmp58_;
3273
ValaCCodeExpressionStatement* _tmp59_;
3274
vala_ccode_function_call_add_argument (vcall, (ValaCCodeExpression*) (_tmp58_ = vala_ccode_identifier_new ("result")));
3275
_vala_ccode_node_unref0 (_tmp58_);
3276
vala_ccode_block_add_statement (block, (ValaCCodeNode*) (_tmp59_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) vcall)));
3284
ValaCCodeIdentifier* _tmp59_;
3285
ValaCCodeExpressionStatement* _tmp60_;
3286
vala_ccode_function_call_add_argument (vcall, (ValaCCodeExpression*) (_tmp59_ = vala_ccode_identifier_new ("result")));
3277
3287
_vala_ccode_node_unref0 (_tmp59_);
3288
vala_ccode_block_add_statement (block, (ValaCCodeNode*) (_tmp60_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) vcall)));
3289
_vala_ccode_node_unref0 (_tmp60_);
3279
ValaCCodeReturnStatement* _tmp63_;
3291
ValaCCodeReturnStatement* _tmp64_;
3280
3292
if (VALA_IS_ARRAY_TYPE (vala_property_accessor_get_value_type (acc))) {
3281
3293
ValaArrayType* array_type;
3282
3294
array_type = _vala_code_node_ref0 (VALA_ARRAY_TYPE (vala_property_accessor_get_value_type (acc)));
3306
3318
_vala_code_node_unref0 (array_type);
3308
vala_ccode_block_add_statement (block, (ValaCCodeNode*) (_tmp63_ = vala_ccode_return_statement_new ((ValaCCodeExpression*) vcall)));
3309
_vala_ccode_node_unref0 (_tmp63_);
3320
vala_ccode_block_add_statement (block, (ValaCCodeNode*) (_tmp64_ = vala_ccode_return_statement_new ((ValaCCodeExpression*) vcall)));
3321
_vala_ccode_node_unref0 (_tmp64_);
3311
3323
_vala_ccode_node_unref0 (vcall);
3313
ValaCCodeMemberAccess* _tmp65_;
3315
ValaCCodeFunctionCall* _tmp66_;
3325
ValaCCodeMemberAccess* _tmp66_;
3327
ValaCCodeFunctionCall* _tmp67_;
3316
3328
ValaCCodeFunctionCall* vcall;
3317
ValaCCodeIdentifier* _tmp67_;
3318
3329
ValaCCodeIdentifier* _tmp68_;
3319
ValaCCodeExpressionStatement* _tmp72_;
3320
vcall = (_tmp66_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp65_ = vala_ccode_member_access_new_pointer ((ValaCCodeExpression*) vcast, _tmp64_ = g_strdup_printf ("set_%s", vala_symbol_get_name ((ValaSymbol*) prop))))), _vala_ccode_node_unref0 (_tmp65_), _g_free0 (_tmp64_), _tmp66_);
3321
vala_ccode_function_call_add_argument (vcall, (ValaCCodeExpression*) (_tmp67_ = vala_ccode_identifier_new ("self")));
3322
_vala_ccode_node_unref0 (_tmp67_);
3323
vala_ccode_function_call_add_argument (vcall, (ValaCCodeExpression*) (_tmp68_ = vala_ccode_identifier_new ("value")));
3330
ValaCCodeIdentifier* _tmp69_;
3331
ValaCCodeExpressionStatement* _tmp73_;
3332
vcall = (_tmp67_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp66_ = vala_ccode_member_access_new_pointer ((ValaCCodeExpression*) vcast, _tmp65_ = g_strdup_printf ("set_%s", vala_symbol_get_name ((ValaSymbol*) prop))))), _vala_ccode_node_unref0 (_tmp66_), _g_free0 (_tmp65_), _tmp67_);
3333
vala_ccode_function_call_add_argument (vcall, (ValaCCodeExpression*) (_tmp68_ = vala_ccode_identifier_new ("self")));
3324
3334
_vala_ccode_node_unref0 (_tmp68_);
3335
vala_ccode_function_call_add_argument (vcall, (ValaCCodeExpression*) (_tmp69_ = vala_ccode_identifier_new ("value")));
3336
_vala_ccode_node_unref0 (_tmp69_);
3325
3337
if (VALA_IS_ARRAY_TYPE (vala_property_accessor_get_value_type (acc))) {
3326
3338
ValaArrayType* array_type;
3327
3339
array_type = _vala_code_node_ref0 (VALA_ARRAY_TYPE (vala_property_accessor_get_value_type (acc)));
3359
3371
_vala_ccode_node_unref0 (block);
3361
3373
if (!vala_property_get_is_abstract (prop)) {
3362
gboolean _tmp73_ = FALSE;
3374
gboolean _tmp74_ = FALSE;
3363
3375
gboolean is_virtual;
3365
gboolean _tmp79_ = FALSE;
3366
3377
gboolean _tmp80_ = FALSE;
3378
gboolean _tmp81_ = FALSE;
3367
3379
ValaObjectType* base_type;
3368
gboolean _tmp88_ = FALSE;
3369
3380
gboolean _tmp89_ = FALSE;
3370
gboolean _tmp108_ = FALSE;
3371
gboolean _tmp116_ = FALSE;
3372
gboolean _tmp120_ = FALSE;
3381
gboolean _tmp90_ = FALSE;
3382
gboolean _tmp109_ = FALSE;
3383
gboolean _tmp117_ = FALSE;
3373
3384
gboolean _tmp121_ = FALSE;
3385
gboolean _tmp122_ = FALSE;
3374
3386
if (vala_property_get_base_property (prop) != NULL) {
3377
_tmp73_ = vala_property_get_base_interface_property (prop) != NULL;
3389
_tmp74_ = vala_property_get_base_interface_property (prop) != NULL;
3379
is_virtual = _tmp73_;
3391
is_virtual = _tmp74_;
3381
3393
if (is_virtual) {
3382
3394
if (vala_property_accessor_get_readable (acc)) {
3385
cname = (_tmp75_ = g_strdup_printf ("%s_real_get_%s", _tmp74_ = vala_symbol_get_lower_case_cname ((ValaSymbol*) t, NULL), vala_symbol_get_name ((ValaSymbol*) prop)), _g_free0 (cname), _tmp75_);
3397
cname = (_tmp76_ = g_strdup_printf ("%s_real_get_%s", _tmp75_ = vala_symbol_get_lower_case_cname ((ValaSymbol*) t, NULL), vala_symbol_get_name ((ValaSymbol*) prop)), _g_free0 (cname), _tmp76_);
3390
cname = (_tmp77_ = g_strdup_printf ("%s_real_set_%s", _tmp76_ = vala_symbol_get_lower_case_cname ((ValaSymbol*) t, NULL), vala_symbol_get_name ((ValaSymbol*) prop)), _g_free0 (cname), _tmp77_);
3402
cname = (_tmp78_ = g_strdup_printf ("%s_real_set_%s", _tmp77_ = vala_symbol_get_lower_case_cname ((ValaSymbol*) t, NULL), vala_symbol_get_name ((ValaSymbol*) prop)), _g_free0 (cname), _tmp78_);
3395
cname = (_tmp78_ = vala_property_accessor_get_cname (acc), _g_free0 (cname), _tmp78_);
3407
cname = (_tmp79_ = vala_property_accessor_get_cname (acc), _g_free0 (cname), _tmp79_);
3397
3409
if (vala_property_accessor_get_writable (acc)) {
3412
_tmp81_ = vala_property_accessor_get_construction (acc);
3398
3415
_tmp80_ = TRUE;
3400
_tmp80_ = vala_property_accessor_get_construction (acc);
3417
_tmp80_ = returns_real_struct;
3405
_tmp79_ = returns_real_struct;
3408
ValaCCodeFunction* _tmp81_;
3409
self->function = (_tmp81_ = vala_ccode_function_new (cname, "void"), _vala_ccode_node_unref0 (self->function), _tmp81_);
3411
ValaCCodeFunction* _tmp83_;
3413
self->function = (_tmp83_ = vala_ccode_function_new (cname, _tmp82_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc))), _vala_ccode_node_unref0 (self->function), _tmp83_);
3420
ValaCCodeFunction* _tmp82_;
3421
self->function = (_tmp82_ = vala_ccode_function_new (cname, "void"), _vala_ccode_node_unref0 (self->function), _tmp82_);
3423
ValaCCodeFunction* _tmp84_;
3425
self->function = (_tmp84_ = vala_ccode_function_new (cname, _tmp83_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc))), _vala_ccode_node_unref0 (self->function), _tmp84_);
3416
3428
base_type = NULL;
3417
3429
if (vala_property_get_binding (prop) == MEMBER_BINDING_INSTANCE) {
3418
3430
if (is_virtual) {
3419
ValaCCodeFormalParameter* _tmp87_;
3431
ValaCCodeFormalParameter* _tmp88_;
3421
3433
if (vala_property_get_base_property (prop) != NULL) {
3422
ValaObjectType* _tmp84_;
3423
base_type = (_tmp84_ = vala_object_type_new (VALA_OBJECT_TYPE_SYMBOL (vala_symbol_get_parent_symbol ((ValaSymbol*) vala_property_get_base_property (prop)))), _vala_code_node_unref0 (base_type), _tmp84_);
3434
ValaObjectType* _tmp85_;
3435
base_type = (_tmp85_ = vala_object_type_new (VALA_OBJECT_TYPE_SYMBOL (vala_symbol_get_parent_symbol ((ValaSymbol*) vala_property_get_base_property (prop)))), _vala_code_node_unref0 (base_type), _tmp85_);
3425
3437
if (vala_property_get_base_interface_property (prop) != NULL) {
3426
ValaObjectType* _tmp85_;
3427
base_type = (_tmp85_ = vala_object_type_new (VALA_OBJECT_TYPE_SYMBOL (vala_symbol_get_parent_symbol ((ValaSymbol*) vala_property_get_base_interface_property (prop)))), _vala_code_node_unref0 (base_type), _tmp85_);
3438
ValaObjectType* _tmp86_;
3439
base_type = (_tmp86_ = vala_object_type_new (VALA_OBJECT_TYPE_SYMBOL (vala_symbol_get_parent_symbol ((ValaSymbol*) vala_property_get_base_interface_property (prop)))), _vala_code_node_unref0 (base_type), _tmp86_);
3430
3442
vala_ccode_function_set_modifiers (self->function, vala_ccode_function_get_modifiers (self->function) | VALA_CCODE_MODIFIERS_STATIC);
3431
vala_ccode_function_add_parameter (self->function, _tmp87_ = vala_ccode_formal_parameter_new ("base", _tmp86_ = vala_data_type_get_cname ((ValaDataType*) base_type)));
3432
_vala_ccode_node_unref0 (_tmp87_);
3443
vala_ccode_function_add_parameter (self->function, _tmp88_ = vala_ccode_formal_parameter_new ("base", _tmp87_ = vala_data_type_get_cname ((ValaDataType*) base_type)));
3444
_vala_ccode_node_unref0 (_tmp88_);
3435
3447
vala_ccode_function_add_parameter (self->function, cselfparam);
3438
3450
if (vala_property_accessor_get_writable (acc)) {
3453
_tmp90_ = vala_property_accessor_get_construction (acc);
3439
3456
_tmp89_ = TRUE;
3441
_tmp89_ = vala_property_accessor_get_construction (acc);
3458
_tmp89_ = returns_real_struct;
3446
_tmp88_ = returns_real_struct;
3449
3461
vala_ccode_function_add_parameter (self->function, cvalueparam);
3451
3463
if (VALA_IS_ARRAY_TYPE (vala_property_accessor_get_value_type (acc))) {
3454
3466
array_type = _vala_code_node_ref0 (VALA_ARRAY_TYPE (vala_property_accessor_get_value_type (acc)));
3455
3467
length_ctype = g_strdup ("int");
3456
3468
if (vala_property_accessor_get_readable (acc)) {
3458
length_ctype = (_tmp90_ = g_strdup ("int*"), _g_free0 (length_ctype), _tmp90_);
3470
length_ctype = (_tmp91_ = g_strdup ("int*"), _g_free0 (length_ctype), _tmp91_);
3467
const char* _tmp92_;
3468
ValaCCodeFormalParameter* _tmp94_;
3479
const char* _tmp93_;
3480
ValaCCodeFormalParameter* _tmp95_;
3474
3486
if (!(dim <= vala_array_type_get_rank (array_type))) {
3478
3490
if (vala_property_accessor_get_readable (acc)) {
3483
vala_ccode_function_add_parameter (self->function, _tmp94_ = vala_ccode_formal_parameter_new (_tmp93_ = vala_ccode_module_get_array_length_cname (vala_ccode_module_get_head ((ValaCCodeModule*) self), _tmp92_, dim), length_ctype));
3484
_vala_ccode_node_unref0 (_tmp94_);
3495
vala_ccode_function_add_parameter (self->function, _tmp95_ = vala_ccode_formal_parameter_new (_tmp94_ = vala_ccode_module_get_array_length_cname (vala_ccode_module_get_head ((ValaCCodeModule*) self), _tmp93_, dim), length_ctype));
3496
_vala_ccode_node_unref0 (_tmp95_);
3489
3501
_g_free0 (length_ctype);
3490
3502
_vala_code_node_unref0 (array_type);
3492
gboolean _tmp95_ = FALSE;
3504
gboolean _tmp96_ = FALSE;
3493
3505
if (VALA_IS_DELEGATE_TYPE (vala_property_accessor_get_value_type (acc))) {
3494
_tmp95_ = vala_delegate_get_has_target (vala_delegate_type_get_delegate_symbol (VALA_DELEGATE_TYPE (vala_property_accessor_get_value_type (acc))));
3506
_tmp96_ = vala_delegate_get_has_target (vala_delegate_type_get_delegate_symbol (VALA_DELEGATE_TYPE (vala_property_accessor_get_value_type (acc))));
3499
const char* _tmp96_;
3500
3511
const char* _tmp97_;
3501
ValaCCodeFormalParameter* _tmp99_;
3504
if (vala_property_accessor_get_readable (acc)) {
3512
const char* _tmp98_;
3513
ValaCCodeFormalParameter* _tmp100_;
3509
3515
_tmp97_ = NULL;
3510
3516
if (vala_property_accessor_get_readable (acc)) {
3511
_tmp97_ = "gpointer*";
3513
_tmp97_ = "gpointer";
3515
vala_ccode_function_add_parameter (self->function, _tmp99_ = vala_ccode_formal_parameter_new (_tmp98_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp96_), _tmp97_));
3516
_vala_ccode_node_unref0 (_tmp99_);
3522
if (vala_property_accessor_get_readable (acc)) {
3523
_tmp98_ = "gpointer*";
3525
_tmp98_ = "gpointer";
3527
vala_ccode_function_add_parameter (self->function, _tmp100_ = vala_ccode_formal_parameter_new (_tmp99_ = vala_ccode_base_module_get_delegate_target_cname (self, _tmp97_), _tmp98_));
3528
_vala_ccode_node_unref0 (_tmp100_);
3520
3532
if (!is_virtual) {
3521
gboolean _tmp100_ = FALSE;
3522
3533
gboolean _tmp101_ = FALSE;
3534
gboolean _tmp102_ = FALSE;
3523
3535
if (vala_symbol_is_private_symbol ((ValaSymbol*) prop)) {
3538
gboolean _tmp103_ = FALSE;
3539
if (vala_property_accessor_get_readable (acc)) {
3542
_tmp103_ = vala_property_accessor_get_writable (acc);
3544
_tmp102_ = !_tmp103_;
3524
3547
_tmp101_ = TRUE;
3526
gboolean _tmp102_ = FALSE;
3527
if (vala_property_accessor_get_readable (acc)) {
3530
_tmp102_ = vala_property_accessor_get_writable (acc);
3532
_tmp101_ = !_tmp102_;
3549
_tmp101_ = vala_symbol_get_access ((ValaSymbol*) acc) == VALA_SYMBOL_ACCESSIBILITY_PRIVATE;
3534
3551
if (_tmp101_) {
3537
_tmp100_ = vala_symbol_get_access ((ValaSymbol*) acc) == VALA_SYMBOL_ACCESSIBILITY_PRIVATE;
3540
3552
vala_ccode_function_set_modifiers (self->function, vala_ccode_function_get_modifiers (self->function) | VALA_CCODE_MODIFIERS_STATIC);
3543
3555
vala_ccode_function_set_block (self->function, VALA_CCODE_BLOCK (vala_code_node_get_ccodenode ((ValaCodeNode*) vala_property_accessor_get_body (acc))));
3544
3556
if (is_virtual) {
3546
ValaCCodeDeclaration* _tmp104_;
3558
ValaCCodeDeclaration* _tmp105_;
3547
3559
ValaCCodeDeclaration* _cdecl_;
3548
ValaCCodeVariableDeclarator* _tmp107_;
3549
ValaCCodeExpression* _tmp106_;
3550
ValaCCodeIdentifier* _tmp105_;
3551
_cdecl_ = (_tmp104_ = vala_ccode_declaration_new (_tmp103_ = vala_data_type_get_cname (this_type)), _g_free0 (_tmp103_), _tmp104_);
3552
vala_ccode_declaration_add_declarator (_cdecl_, (ValaCCodeDeclarator*) (_tmp107_ = vala_ccode_variable_declarator_new ("self", _tmp106_ = vala_ccode_base_module_transform_expression (self, (ValaCCodeExpression*) (_tmp105_ = vala_ccode_identifier_new ("base")), (ValaDataType*) base_type, this_type, NULL), NULL)));
3560
ValaCCodeVariableDeclarator* _tmp108_;
3561
ValaCCodeExpression* _tmp107_;
3562
ValaCCodeIdentifier* _tmp106_;
3563
_cdecl_ = (_tmp105_ = vala_ccode_declaration_new (_tmp104_ = vala_data_type_get_cname (this_type)), _g_free0 (_tmp104_), _tmp105_);
3564
vala_ccode_declaration_add_declarator (_cdecl_, (ValaCCodeDeclarator*) (_tmp108_ = vala_ccode_variable_declarator_new ("self", _tmp107_ = vala_ccode_base_module_transform_expression (self, (ValaCCodeExpression*) (_tmp106_ = vala_ccode_identifier_new ("base")), (ValaDataType*) base_type, this_type, NULL), NULL)));
3565
_vala_ccode_node_unref0 (_tmp108_);
3553
3566
_vala_ccode_node_unref0 (_tmp107_);
3554
3567
_vala_ccode_node_unref0 (_tmp106_);
3555
_vala_ccode_node_unref0 (_tmp105_);
3556
3568
vala_ccode_block_prepend_statement (vala_ccode_function_get_block (self->function), (ValaCCodeNode*) _cdecl_);
3557
3569
_vala_ccode_node_unref0 (_cdecl_);
3559
3571
if (vala_property_accessor_get_readable (acc)) {
3560
_tmp108_ = !returns_real_struct;
3572
_tmp109_ = !returns_real_struct;
3565
gboolean _tmp109_ = FALSE;
3577
gboolean _tmp110_ = FALSE;
3566
3578
if (vala_property_accessor_get_return_block (acc) == NULL) {
3570
_tmp109_ = vala_collection_get_size ((ValaCollection*) (_tmp110_ = vala_basic_block_get_predecessors (vala_property_accessor_get_return_block (acc)))) > 0;
3571
_vala_collection_object_unref0 (_tmp110_);
3582
_tmp110_ = vala_collection_get_size ((ValaCollection*) (_tmp111_ = vala_basic_block_get_predecessors (vala_property_accessor_get_return_block (acc)))) > 0;
3583
_vala_collection_object_unref0 (_tmp111_);
3575
ValaCCodeDeclaration* _tmp112_;
3587
ValaCCodeDeclaration* _tmp113_;
3576
3588
ValaCCodeDeclaration* _cdecl_;
3577
ValaCCodeVariableDeclarator* _tmp113_;
3578
_cdecl_ = (_tmp112_ = vala_ccode_declaration_new (_tmp111_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc))), _g_free0 (_tmp111_), _tmp112_);
3579
vala_ccode_declaration_add_declarator (_cdecl_, (ValaCCodeDeclarator*) (_tmp113_ = vala_ccode_variable_declarator_new ("result", NULL, NULL)));
3580
_vala_ccode_node_unref0 (_tmp113_);
3589
ValaCCodeVariableDeclarator* _tmp114_;
3590
_cdecl_ = (_tmp113_ = vala_ccode_declaration_new (_tmp112_ = vala_data_type_get_cname (vala_property_accessor_get_value_type (acc))), _g_free0 (_tmp112_), _tmp113_);
3591
vala_ccode_declaration_add_declarator (_cdecl_, (ValaCCodeDeclarator*) (_tmp114_ = vala_ccode_variable_declarator_new ("result", NULL, NULL)));
3592
_vala_ccode_node_unref0 (_tmp114_);
3581
3593
vala_ccode_block_prepend_statement (vala_ccode_function_get_block (self->function), (ValaCCodeNode*) _cdecl_);
3582
3594
_vala_ccode_node_unref0 (_cdecl_);
3585
3597
if (self->current_method_inner_error) {
3586
3598
ValaCCodeDeclaration* _cdecl_;
3587
ValaCCodeVariableDeclarator* _tmp115_;
3588
ValaCCodeConstant* _tmp114_;
3599
ValaCCodeVariableDeclarator* _tmp116_;
3600
ValaCCodeConstant* _tmp115_;
3589
3601
_cdecl_ = vala_ccode_declaration_new ("GError *");
3590
vala_ccode_declaration_add_declarator (_cdecl_, (ValaCCodeDeclarator*) (_tmp115_ = vala_ccode_variable_declarator_new ("_inner_error_", (ValaCCodeExpression*) (_tmp114_ = vala_ccode_constant_new ("NULL")), NULL)));
3602
vala_ccode_declaration_add_declarator (_cdecl_, (ValaCCodeDeclarator*) (_tmp116_ = vala_ccode_variable_declarator_new ("_inner_error_", (ValaCCodeExpression*) (_tmp115_ = vala_ccode_constant_new ("NULL")), NULL)));
3603
_vala_ccode_node_unref0 (_tmp116_);
3591
3604
_vala_ccode_node_unref0 (_tmp115_);
3592
_vala_ccode_node_unref0 (_tmp114_);
3593
3605
vala_ccode_block_prepend_statement (vala_ccode_function_get_block (self->function), (ValaCCodeNode*) _cdecl_);
3594
3606
_vala_ccode_node_unref0 (_cdecl_);
3596
3608
if (vala_property_get_binding (prop) == MEMBER_BINDING_INSTANCE) {
3597
_tmp116_ = !is_virtual;
3609
_tmp117_ = !is_virtual;
3602
3614
ValaCCodeStatement* check_stmt;
3603
gboolean _tmp117_ = FALSE;
3615
gboolean _tmp118_ = FALSE;
3604
3616
check_stmt = NULL;
3605
3617
if (!vala_property_accessor_get_readable (acc)) {
3608
_tmp117_ = returns_real_struct;
3620
_tmp118_ = returns_real_struct;
3611
ValaCCodeStatement* _tmp118_;
3612
check_stmt = (_tmp118_ = vala_ccode_base_module_create_property_type_check_statement (self, prop, FALSE, t, TRUE, "self"), _vala_ccode_node_unref0 (check_stmt), _tmp118_);
3614
3623
ValaCCodeStatement* _tmp119_;
3615
check_stmt = (_tmp119_ = vala_ccode_base_module_create_property_type_check_statement (self, prop, TRUE, t, TRUE, "self"), _vala_ccode_node_unref0 (check_stmt), _tmp119_);
3624
check_stmt = (_tmp119_ = vala_ccode_base_module_create_property_type_check_statement (self, prop, FALSE, t, TRUE, "self"), _vala_ccode_node_unref0 (check_stmt), _tmp119_);
3626
ValaCCodeStatement* _tmp120_;
3627
check_stmt = (_tmp120_ = vala_ccode_base_module_create_property_type_check_statement (self, prop, TRUE, t, TRUE, "self"), _vala_ccode_node_unref0 (check_stmt), _tmp120_);
3617
3629
if (check_stmt != NULL) {
3618
3630
vala_ccode_block_prepend_statement (vala_ccode_function_get_block (self->function), (ValaCCodeNode*) check_stmt);
3620
3632
_vala_ccode_node_unref0 (check_stmt);
3622
3634
if (vala_ccode_base_module_is_gobject_property (self, prop)) {
3623
_tmp121_ = vala_property_get_notify (prop);
3635
_tmp122_ = vala_property_get_notify (prop);
3640
gboolean _tmp123_ = FALSE;
3641
if (vala_property_accessor_get_writable (acc)) {
3644
_tmp123_ = vala_property_accessor_get_construction (acc);
3646
_tmp121_ = _tmp123_;
3625
3648
_tmp121_ = FALSE;
3627
3650
if (_tmp121_) {
3628
gboolean _tmp122_ = FALSE;
3629
if (vala_property_accessor_get_writable (acc)) {
3632
_tmp122_ = vala_property_accessor_get_construction (acc);
3634
_tmp120_ = _tmp122_;
3639
ValaCCodeIdentifier* _tmp123_;
3640
ValaCCodeFunctionCall* _tmp124_;
3651
ValaCCodeIdentifier* _tmp124_;
3652
ValaCCodeFunctionCall* _tmp125_;
3641
3653
ValaCCodeFunctionCall* notify_call;
3642
ValaCCodeCastExpression* _tmp126_;
3643
ValaCCodeIdentifier* _tmp125_;
3644
ValaCCodeConstant* _tmp127_;
3645
ValaCCodeExpressionStatement* _tmp128_;
3646
notify_call = (_tmp124_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp123_ = vala_ccode_identifier_new ("g_object_notify"))), _vala_ccode_node_unref0 (_tmp123_), _tmp124_);
3647
vala_ccode_function_call_add_argument (notify_call, (ValaCCodeExpression*) (_tmp126_ = vala_ccode_cast_expression_new ((ValaCCodeExpression*) (_tmp125_ = vala_ccode_identifier_new ("self")), "GObject *")));
3654
ValaCCodeCastExpression* _tmp127_;
3655
ValaCCodeIdentifier* _tmp126_;
3656
ValaCCodeConstant* _tmp128_;
3657
ValaCCodeExpressionStatement* _tmp129_;
3658
notify_call = (_tmp125_ = vala_ccode_function_call_new ((ValaCCodeExpression*) (_tmp124_ = vala_ccode_identifier_new ("g_object_notify"))), _vala_ccode_node_unref0 (_tmp124_), _tmp125_);
3659
vala_ccode_function_call_add_argument (notify_call, (ValaCCodeExpression*) (_tmp127_ = vala_ccode_cast_expression_new ((ValaCCodeExpression*) (_tmp126_ = vala_ccode_identifier_new ("self")), "GObject *")));
3660
_vala_ccode_node_unref0 (_tmp127_);
3648
3661
_vala_ccode_node_unref0 (_tmp126_);
3649
_vala_ccode_node_unref0 (_tmp125_);
3650
vala_ccode_function_call_add_argument (notify_call, (ValaCCodeExpression*) (_tmp127_ = vala_property_get_canonical_cconstant (prop)));
3651
_vala_ccode_node_unref0 (_tmp127_);
3652
vala_ccode_block_add_statement (vala_ccode_function_get_block (self->function), (ValaCCodeNode*) (_tmp128_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) notify_call)));
3662
vala_ccode_function_call_add_argument (notify_call, (ValaCCodeExpression*) (_tmp128_ = vala_property_get_canonical_cconstant (prop)));
3653
3663
_vala_ccode_node_unref0 (_tmp128_);
3664
vala_ccode_block_add_statement (vala_ccode_function_get_block (self->function), (ValaCCodeNode*) (_tmp129_ = vala_ccode_expression_statement_new ((ValaCCodeExpression*) notify_call)));
3665
_vala_ccode_node_unref0 (_tmp129_);
3654
3666
_vala_ccode_node_unref0 (notify_call);
3656
3668
vala_ccode_fragment_append (self->source_type_member_definition, (ValaCCodeNode*) self->function);
3657
3669
_vala_code_node_unref0 (base_type);
3658
3670
_g_free0 (cname);
3660
self->current_symbol = (_tmp129_ = _vala_code_node_ref0 (old_symbol), _vala_code_node_unref0 (self->current_symbol), _tmp129_);
3672
self->current_symbol = (_tmp130_ = _vala_code_node_ref0 (old_symbol), _vala_code_node_unref0 (self->current_symbol), _tmp130_);
3661
3673
self->current_method_inner_error = old_method_inner_error;
3662
3674
_vala_ccode_node_unref0 (cvalueparam);
3663
3675
_vala_ccode_node_unref0 (cselfparam);
3743
3755
g_return_if_fail (data != NULL);
3744
3756
g_return_if_fail (cblock != NULL);
3745
3757
g_return_if_fail (free_block != NULL);
3746
vala_ccode_base_module_generate_type_declaration (self, vala_formal_parameter_get_parameter_type (param), self->source_declarations);
3747
param_type = vala_data_type_copy (vala_formal_parameter_get_parameter_type (param));
3758
vala_ccode_base_module_generate_type_declaration (self, vala_variable_get_variable_type ((ValaVariable*) param), self->source_declarations);
3759
param_type = vala_data_type_copy (vala_variable_get_variable_type ((ValaVariable*) param));
3748
3760
vala_data_type_set_value_owned (param_type, TRUE);
3749
3761
vala_ccode_struct_add_field (data, _tmp0_ = vala_data_type_get_cname (param_type), _tmp1_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) param)), NULL);
3750
3762
_g_free0 (_tmp1_);
3751
3763
_g_free0 (_tmp0_);
3752
if (VALA_IS_DELEGATE_TYPE (vala_formal_parameter_get_parameter_type (param))) {
3753
_tmp2_ = !vala_data_type_get_value_owned (vala_formal_parameter_get_parameter_type (param));
3764
if (VALA_IS_DELEGATE_TYPE (vala_variable_get_variable_type ((ValaVariable*) param))) {
3765
_tmp2_ = !vala_data_type_get_value_owned (vala_variable_get_variable_type ((ValaVariable*) param));
3755
3767
_tmp2_ = FALSE;
3757
3769
is_unowned_delegate = _tmp2_;
3758
3770
cparam = vala_ccode_base_module_get_variable_cexpression (self, vala_symbol_get_name ((ValaSymbol*) param));
3759
if (vala_data_type_is_real_non_null_struct_type (vala_formal_parameter_get_parameter_type (param))) {
3771
if (vala_data_type_is_real_non_null_struct_type (vala_variable_get_variable_type ((ValaVariable*) param))) {
3760
3772
ValaCCodeExpression* _tmp3_;
3761
3773
cparam = (_tmp3_ = (ValaCCodeExpression*) vala_ccode_unary_expression_new (VALA_CCODE_UNARY_OPERATOR_POINTER_INDIRECTION, cparam), _vala_ccode_node_unref0 (cparam), _tmp3_);
3763
3775
if (vala_ccode_base_module_requires_copy (self, param_type)) {
3764
_tmp5_ = !vala_data_type_get_value_owned (vala_formal_parameter_get_parameter_type (param));
3776
_tmp5_ = !vala_data_type_get_value_owned (vala_variable_get_variable_type ((ValaVariable*) param));
3766
3778
_tmp5_ = FALSE;
5230
5242
post_stmt = (_tmp80_ = (ValaCCodeStatement*) vala_ccode_expression_statement_new (rhs), _vala_ccode_node_unref0 (post_stmt), _tmp80_);
5231
5243
rhs = (_tmp81_ = NULL, _vala_ccode_node_unref0 (rhs), _tmp81_);
5233
cvar = (_tmp84_ = vala_ccode_variable_declarator_new (_tmp82_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) local)), rhs, _tmp83_ = vala_data_type_get_cdeclarator_suffix (vala_local_variable_get_variable_type (local))), _g_free0 (_tmp83_), _g_free0 (_tmp82_), _tmp84_);
5245
cvar = (_tmp84_ = vala_ccode_variable_declarator_new (_tmp82_ = vala_ccode_base_module_get_variable_cname (self, vala_symbol_get_name ((ValaSymbol*) local)), rhs, _tmp83_ = vala_data_type_get_cdeclarator_suffix (vala_variable_get_variable_type ((ValaVariable*) local))), _g_free0 (_tmp83_), _g_free0 (_tmp82_), _tmp84_);
5234
5246
if (rhs != NULL) {
5235
5247
vala_ccode_node_set_line ((ValaCCodeNode*) cvar, vala_ccode_node_get_line ((ValaCCodeNode*) rhs));
5237
_cdecl_ = (_tmp86_ = vala_ccode_declaration_new (_tmp85_ = vala_data_type_get_cname (vala_local_variable_get_variable_type (local))), _g_free0 (_tmp85_), _tmp86_);
5249
_cdecl_ = (_tmp86_ = vala_ccode_declaration_new (_tmp85_ = vala_data_type_get_cname (vala_variable_get_variable_type ((ValaVariable*) local))), _g_free0 (_tmp85_), _tmp86_);
5238
5250
vala_ccode_declaration_add_declarator (_cdecl_, (ValaCCodeDeclarator*) cvar);
5239
5251
vala_ccode_fragment_append (cfrag, (ValaCCodeNode*) _cdecl_);
5240
5252
if (vala_ccode_variable_declarator_get_initializer (cvar) == NULL) {
5241
5253
ValaCCodeExpression* _tmp87_;
5242
vala_ccode_variable_declarator_set_initializer (cvar, _tmp87_ = vala_ccode_base_module_default_value_for_type (self, vala_local_variable_get_variable_type (local), TRUE));
5254
vala_ccode_variable_declarator_set_initializer (cvar, _tmp87_ = vala_ccode_base_module_default_value_for_type (self, vala_variable_get_variable_type ((ValaVariable*) local), TRUE));
5243
5255
_vala_ccode_node_unref0 (_tmp87_);
5244
5256
vala_ccode_variable_declarator_set_init0 (cvar, TRUE);
7221
7233
local = (ValaLocalVariable*) vala_iterator_get (_local_it);
7222
_cdecl_ = (_tmp1_ = vala_ccode_declaration_new (_tmp0_ = vala_data_type_get_cname (vala_local_variable_get_variable_type (local))), _g_free0 (_tmp0_), _tmp1_);
7223
vardecl = (_tmp3_ = vala_ccode_variable_declarator_new (vala_symbol_get_name ((ValaSymbol*) local), NULL, _tmp2_ = vala_data_type_get_cdeclarator_suffix (vala_local_variable_get_variable_type (local))), _g_free0 (_tmp2_), _tmp3_);
7234
_cdecl_ = (_tmp1_ = vala_ccode_declaration_new (_tmp0_ = vala_data_type_get_cname (vala_variable_get_variable_type ((ValaVariable*) local))), _g_free0 (_tmp0_), _tmp1_);
7235
vardecl = (_tmp3_ = vala_ccode_variable_declarator_new (vala_symbol_get_name ((ValaSymbol*) local), NULL, _tmp2_ = vala_data_type_get_cdeclarator_suffix (vala_variable_get_variable_type ((ValaVariable*) local))), _g_free0 (_tmp2_), _tmp3_);
7224
7236
vala_code_node_set_ccodenode ((ValaCodeNode*) local, (ValaCCodeNode*) vardecl);
7225
7237
vala_ccode_declaration_add_declarator (_cdecl_, (ValaCCodeDeclarator*) vardecl);
7226
st = _vala_code_node_ref0 ((_tmp4_ = vala_data_type_get_data_type (vala_local_variable_get_variable_type (local)), VALA_IS_STRUCT (_tmp4_) ? ((ValaStruct*) _tmp4_) : NULL));
7227
array_type = _vala_code_node_ref0 ((_tmp5_ = vala_local_variable_get_variable_type (local), VALA_IS_ARRAY_TYPE (_tmp5_) ? ((ValaArrayType*) _tmp5_) : NULL));
7238
st = _vala_code_node_ref0 ((_tmp4_ = vala_data_type_get_data_type (vala_variable_get_variable_type ((ValaVariable*) local)), VALA_IS_STRUCT (_tmp4_) ? ((ValaStruct*) _tmp4_) : NULL));
7239
array_type = _vala_code_node_ref0 ((_tmp5_ = vala_variable_get_variable_type ((ValaVariable*) local), VALA_IS_ARRAY_TYPE (_tmp5_) ? ((ValaArrayType*) _tmp5_) : NULL));
7228
7240
if (g_str_has_prefix (vala_symbol_get_name ((ValaSymbol*) local), "*")) {
7230
7242
if (vala_local_variable_get_no_init (local)) {
7232
7244
gboolean _tmp6_ = FALSE;
7233
7245
gboolean _tmp7_ = FALSE;
7234
if (!vala_data_type_get_nullable (vala_local_variable_get_variable_type (local))) {
7246
if (!vala_data_type_get_nullable (vala_variable_get_variable_type ((ValaVariable*) local))) {
7235
7247
gboolean _tmp8_ = FALSE;
7236
7248
if (st != NULL) {
7237
7249
_tmp8_ = !vala_struct_is_simple_type (st);