Index: gobject/valagobjectmodule.vala
===================================================================
--- gobject/valagobjectmodule.vala	(revision 2057)
+++ gobject/valagobjectmodule.vala	(working copy)
@@ -1504,77 +1513,106 @@
 		var cl = (Class) c.parent_symbol;
 
 		if (c.binding == MemberBinding.INSTANCE) {
-			function = new CCodeFunction ("%s_constructor".printf (cl.get_lower_case_cname (null)), "GObject *");
-			function.modifiers = CCodeModifiers.STATIC;
-		
-			function.add_parameter (new CCodeFormalParameter ("type", "GType"));
-			function.add_parameter (new CCodeFormalParameter ("n_construct_properties", "guint"));
-			function.add_parameter (new CCodeFormalParameter ("construct_properties", "GObjectConstructParam *"));
-		
-			source_type_member_declaration.append (function.copy ());
+			if(cl.is_subtype_of(gobject_type)) {
+				function = new CCodeFunction ("%s_constructor".printf (cl.get_lower_case_cname (null)), "GObject *");
+				function.modifiers = CCodeModifiers.STATIC;
+			
+				function.add_parameter (new CCodeFormalParameter ("type", "GType"));
+				function.add_parameter (new CCodeFormalParameter ("n_construct_properties", "guint"));
+				function.add_parameter (new CCodeFormalParameter ("construct_properties", "GObjectConstructParam *"));
+				source_type_member_declaration.append (function.copy ());
 
 
-			var cblock = new CCodeBlock ();
-			var cdecl = new CCodeDeclaration ("GObject *");
-			cdecl.add_declarator (new CCodeVariableDeclarator ("obj"));
-			cblock.add_statement (cdecl);
+				var cblock = new CCodeBlock ();
+				var cdecl = new CCodeDeclaration ("GObject *");
+				cdecl.add_declarator (new CCodeVariableDeclarator ("obj"));
+				cblock.add_statement (cdecl);
 
-			cdecl = new CCodeDeclaration ("%sClass *".printf (cl.get_cname ()));
-			cdecl.add_declarator (new CCodeVariableDeclarator ("klass"));
-			cblock.add_statement (cdecl);
+				cdecl = new CCodeDeclaration ("%sClass *".printf (cl.get_cname ()));
+				cdecl.add_declarator (new CCodeVariableDeclarator ("klass"));
+				cblock.add_statement (cdecl);
 
-			cdecl = new CCodeDeclaration ("GObjectClass *");
-			cdecl.add_declarator (new CCodeVariableDeclarator ("parent_class"));
-			cblock.add_statement (cdecl);
+				cdecl = new CCodeDeclaration ("GObjectClass *");
+				cdecl.add_declarator (new CCodeVariableDeclarator ("parent_class"));
+				cblock.add_statement (cdecl);
 
 
-			var ccall = new CCodeFunctionCall (new CCodeIdentifier ("g_type_class_peek"));
-			ccall.add_argument (new CCodeIdentifier (cl.get_type_id ()));
-			var ccast = new CCodeFunctionCall (new CCodeIdentifier ("%s_CLASS".printf (cl.get_upper_case_cname (null))));
-			ccast.add_argument (ccall);
-			cblock.add_statement (new CCodeExpressionStatement (new CCodeAssignment (new CCodeIdentifier ("klass"), ccast)));
+				var ccall = new CCodeFunctionCall (new CCodeIdentifier ("g_type_class_peek"));
+				ccall.add_argument (new CCodeIdentifier (cl.get_type_id ()));
+				var ccast = new CCodeFunctionCall (new CCodeIdentifier ("%s_CLASS".printf (cl.get_upper_case_cname (null))));
+				ccast.add_argument (ccall);
+				cblock.add_statement (new CCodeExpressionStatement (new CCodeAssignment (new CCodeIdentifier ("klass"), ccast)));
 
-			ccall = new CCodeFunctionCall (new CCodeIdentifier ("g_type_class_peek_parent"));
-			ccall.add_argument (new CCodeIdentifier ("klass"));
-			ccast = new CCodeFunctionCall (new CCodeIdentifier ("G_OBJECT_CLASS"));
-			ccast.add_argument (ccall);
-			cblock.add_statement (new CCodeExpressionStatement (new CCodeAssignment (new CCodeIdentifier ("parent_class"), ccast)));
+				ccall = new CCodeFunctionCall (new CCodeIdentifier ("g_type_class_peek_parent"));
+				ccall.add_argument (new CCodeIdentifier ("klass"));
+				ccast = new CCodeFunctionCall (new CCodeIdentifier ("G_OBJECT_CLASS"));
+				ccast.add_argument (ccall);
+				cblock.add_statement (new CCodeExpressionStatement (new CCodeAssignment (new CCodeIdentifier ("parent_class"), ccast)));
 
-		
-			ccall = new CCodeFunctionCall (new CCodeMemberAccess.pointer (new CCodeIdentifier ("parent_class"), "constructor"));
-			ccall.add_argument (new CCodeIdentifier ("type"));
-			ccall.add_argument (new CCodeIdentifier ("n_construct_properties"));
-			ccall.add_argument (new CCodeIdentifier ("construct_properties"));
-			cblock.add_statement (new CCodeExpressionStatement (new CCodeAssignment (new CCodeIdentifier ("obj"), ccall)));
+			
+				ccall = new CCodeFunctionCall (new CCodeMemberAccess.pointer (new CCodeIdentifier ("parent_class"), "constructor"));
+				ccall.add_argument (new CCodeIdentifier ("type"));
+				ccall.add_argument (new CCodeIdentifier ("n_construct_properties"));
+				ccall.add_argument (new CCodeIdentifier ("construct_properties"));
+				cblock.add_statement (new CCodeExpressionStatement (new CCodeAssignment (new CCodeIdentifier ("obj"), ccall)));
 
 
-			ccall = new InstanceCast (new CCodeIdentifier ("obj"), cl);
+				ccall = new InstanceCast (new CCodeIdentifier ("obj"), cl);
 
-			cdecl = new CCodeDeclaration ("%s *".printf (cl.get_cname ()));
-			cdecl.add_declarator (new CCodeVariableDeclarator.with_initializer ("self", ccall));
-		
-			cblock.add_statement (cdecl);
-
-			if (current_method_inner_error) {
-				/* always separate error parameter and inner_error local variable
-				 * as error may be set to NULL but we're always interested in inner errors
-				 */
-				var cdecl = new CCodeDeclaration ("GError *");
-				cdecl.add_declarator (new CCodeVariableDeclarator.with_initializer ("inner_error", new CCodeConstant ("NULL")));
+				cdecl = new CCodeDeclaration ("%s *".printf (cl.get_cname ()));
+				cdecl.add_declarator (new CCodeVariableDeclarator.with_initializer ("self", ccall));
+			
 				cblock.add_statement (cdecl);
-			}
 
+				if (current_method_inner_error) {
+					/* always separate error parameter and inner_error local variable
+					 * as error may be set to NULL but we're always interested in inner errors
+					 */
+					var cdecl = new CCodeDeclaration ("GError *");
+					cdecl.add_declarator (new CCodeVariableDeclarator.with_initializer ("inner_error", new CCodeConstant ("NULL")));
+					cblock.add_statement (cdecl);
+				}
 
-			cblock.add_statement (c.body.ccodenode);
-		
-			cblock.add_statement (new CCodeReturnStatement (new CCodeIdentifier ("obj")));
-		
-			function.block = cblock;
 
-			if (c.source_reference.comment != null) {
-				source_type_member_definition.append (new CCodeComment (c.source_reference.comment));
+				cblock.add_statement (c.body.ccodenode);
+			
+				cblock.add_statement (new CCodeReturnStatement (new CCodeIdentifier ("obj")));
+			
+				function.block = cblock;
+
+				if (c.source_reference.comment != null) {
+					source_type_member_definition.append (new CCodeComment (c.source_reference.comment));
+				}
+				source_type_member_definition.append (function);
+			} else {
+				function = new CCodeFunction ("%s_constructor".printf (cl.get_lower_case_cname (null)), "void");
+				function.add_parameter (new CCodeFormalParameter ("self", cl.get_cname() + "*"));
+
+				source_type_member_declaration.append (function.copy ());
+
+				var cblock = new CCodeBlock ();
+
+				if (current_method_inner_error) {
+					/* always separate error parameter and inner_error local variable
+					 * as error may be set to NULL but we're always interested in inner errors
+					 */
+					var cdecl = new CCodeDeclaration ("GError *");
+					cdecl.add_declarator (new CCodeVariableDeclarator.with_initializer ("inner_error", new CCodeConstant ("NULL")));
+					cblock.add_statement (cdecl);
+				}
+
+				cblock.add_statement (c.body.ccodenode);
+			
+				cblock.add_statement (new CCodeReturnStatement ());
+			
+				function.block = cblock;
+
+				if (c.source_reference.comment != null) {
+					source_type_member_definition.append (new CCodeComment (c.source_reference.comment));
+				}
+				source_type_member_definition.append (function);
 			}
-			source_type_member_definition.append (function);
+		
 		} else if (c.binding == MemberBinding.CLASS) {
 			// class constructor
 
Index: gobject/valaccodemethodmodule.vala
===================================================================
--- gobject/valaccodemethodmodule.vala	(revision 2057)
+++ gobject/valaccodemethodmodule.vala	(working copy)
@@ -880,6 +880,13 @@
 			function.block.add_statement (new CCodeExpressionStatement (cfreeparams));
 		}
 
+		if (current_class != null && !current_class.is_compact && !current_class.is_subtype_of(gobject_type)
+				&& current_class.constructor != null) {
+			var vcall = new CCodeFunctionCall (new CCodeIdentifier("%s_constructor".printf (current_class.get_lower_case_cname (null))));
+			vcall.add_argument (new CCodeIdentifier ("self"));
+			function.block.add_statement ( new CCodeExpressionStatement (vcall));
+		}
+
 		if (current_type_symbol is Class) {
 			CCodeExpression cresult = new CCodeIdentifier ("self");
 			if (get_custom_creturn_type (m) != null) {
