[vala/staging: 1/2] codegen: Pass pointer of matching type to property-getter



commit 8036f870f57603b8572718d1a0ec147ed18deab7
Author: Rico Tzschichholz <ricotz ubuntu com>
Date:   Sat Feb 25 13:07:11 2017 +0100

    codegen: Pass pointer of matching type to property-getter
    
    https://bugzilla.gnome.org/show_bug.cgi?id=777958

 codegen/valaccodebasemodule.vala |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/codegen/valaccodebasemodule.vala b/codegen/valaccodebasemodule.vala
index 880e8a2..9512895 100644
--- a/codegen/valaccodebasemodule.vala
+++ b/codegen/valaccodebasemodule.vala
@@ -1782,7 +1782,7 @@ public abstract class Vala.CCodeBaseModule : CodeGenerator {
                                if (get_accessor != null) {
                                        var property_type = prop.property_type;
                                        var get_call = new CCodeFunctionCall (new CCodeIdentifier 
(get_ccode_real_name (get_accessor)));
-                                       get_call.add_argument (new CCodeIdentifier ("self"));
+                                       get_call.add_argument (new CCodeIdentifier (is_virtual ? "base" : 
"self"));
 
                                        if (property_type is ArrayType) {
                                                ccode.add_declaration ("int", new CCodeVariableDeclarator 
("old_value_length"));


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]