type_init.add_statement (new CCodeExpressionStatement (add_class_private_call));
}
+ if (!declaration_only) {
+ get_type_interface_init_statements (context, type_init, plugin);
+ }
+
if (cl != null && (cl.has_private_fields || cl.get_type_parameters ().size > 0)) {
var ccall = new CCodeFunctionCall (new CCodeIdentifier ("g_type_add_instance_private"));
ccall.add_argument (new CCodeIdentifier (type_id_name));
type_init.add_statement (new CCodeExpressionStatement (new CCodeAssignment (new CCodeIdentifier ("%s_private_offset".printf (get_ccode_name (cl))), ccall)));
}
- if (!declaration_only) {
- get_type_interface_init_statements (context, type_init, plugin);
- }
-
if (!plugin) {
CCodeExpression condition; // the condition that guards the type initialisation
if (use_thread_safe) {