]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
Fix constructor chain up to generic compact classes
authorJürg Billeter <j@bitron.ch>
Sat, 20 Mar 2010 15:40:56 +0000 (16:40 +0100)
committerJürg Billeter <j@bitron.ch>
Sat, 20 Mar 2010 15:40:56 +0000 (16:40 +0100)
Fixes bug 594063.

codegen/valaccodemethodcallmodule.vala

index 5c88ef95a6cf03d56b572bc526f9211a80116519..f19bf514d9e02297193645294455ec13b3ede108 100644 (file)
@@ -129,10 +129,12 @@ internal class Vala.CCodeMethodCallModule : CCodeAssignmentModule {
                                ccall.add_argument (new CCodeIdentifier ("self"));
                        }
 
-                       foreach (DataType base_type in current_class.get_base_types ()) {
-                               if (base_type.data_type is Class) {
-                                       add_generic_type_arguments (in_arg_map, base_type.get_type_arguments (), expr, true);
-                                       break;
+                       if (!current_class.is_compact) {
+                               foreach (DataType base_type in current_class.get_base_types ()) {
+                                       if (base_type.data_type is Class) {
+                                               add_generic_type_arguments (in_arg_map, base_type.get_type_arguments (), expr, true);
+                                               break;
+                                       }
                                }
                        }
                } else if (m is CreationMethod && m.parent_symbol is Struct) {