[vala] GObject: Do not use G_PARAM_WRITABLE for private setters



commit c070d47030d7497a441416507e1b1c243c8426ab
Author: Jürg Billeter <j bitron ch>
Date:   Sat Aug 1 18:28:57 2009 +0200

    GObject: Do not use G_PARAM_WRITABLE for private setters
    
    Fixes bug 589310.

 codegen/valagtypemodule.vala |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/codegen/valagtypemodule.vala b/codegen/valagtypemodule.vala
index e534cfe..29dc0e0 100644
--- a/codegen/valagtypemodule.vala
+++ b/codegen/valagtypemodule.vala
@@ -1656,10 +1656,10 @@ internal class Vala.GTypeModule : GErrorModule {
 		}
 		
 		var pflags = "G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB";
-		if (prop.get_accessor != null) {
+		if (prop.get_accessor != null && prop.get_accessor.access != SymbolAccessibility.PRIVATE) {
 			pflags = "%s%s".printf (pflags, " | G_PARAM_READABLE");
 		}
-		if (prop.set_accessor != null) {
+		if (prop.set_accessor != null && prop.set_accessor.access != SymbolAccessibility.PRIVATE) {
 			pflags = "%s%s".printf (pflags, " | G_PARAM_WRITABLE");
 			if (prop.set_accessor.construction) {
 				if (prop.set_accessor.writable) {



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