[vala/wip/attributes: 55/121] gidlparser: Drop usage of set_free_function and others



commit 7361c9d870c1600e3aaaa6399974c8ef69c58555
Author: Luca Bruno <lucabru src gnome org>
Date:   Wed Jun 29 15:47:11 2011 +0200

    gidlparser: Drop usage of set_free_function and others

 vapigen/valagidlparser.vala |   32 ++++++++++++++++----------------
 1 files changed, 16 insertions(+), 16 deletions(-)
---
diff --git a/vapigen/valagidlparser.vala b/vapigen/valagidlparser.vala
index 9df5465..93d3bee 100644
--- a/vapigen/valagidlparser.vala
+++ b/vapigen/valagidlparser.vala
@@ -435,7 +435,7 @@ public class Vala.GIdlParser : CodeVisitor {
 			cc = cp.scope.lookup (tok) as Symbol;
 			if ( cc == null ) {
 				cc = new Namespace (tok, current_source_reference);
-				cc.set_attribute_string ("CCode", "cprefix", get_cprefix (cp), + tok);
+				cc.set_attribute_string ("CCode", "cprefix", get_cprefix (cp) + tok);
 				add_symbol_to_container (cp, cc);
 			}
 			cp = cc;
@@ -920,16 +920,16 @@ public class Vala.GIdlParser : CodeVisitor {
 			}
 
 			if (ref_function != null) {
-				cl.set_ref_function (ref_function);
-				cl.ref_function_void = ref_function_void;
+				cl.set_attribute_string ("CCode", "ref_function", ref_function);
+				cl.set_attribute_string ("CCOde", "ref_function_void", ref_function_void);
 			}
 			if (copy_function != null) {
-				cl.set_dup_function (copy_function);
+				cl.set_attribute_string ("CCode", "copy_function", copy_function);
 			}
 			if (unref_function != null) {
-				cl.set_unref_function (unref_function);
+				cl.set_attribute_string ("CCode", "unref_function", unref_function);
 			} else if (free_function != null) {
-				cl.set_free_function (free_function);
+				cl.set_attribute_string ("CCode", "free_function", free_function);
 			}
 
 			current_data_type = null;
@@ -1058,16 +1058,16 @@ public class Vala.GIdlParser : CodeVisitor {
 			}
 
 			if (ref_function != null) {
-				cl.set_ref_function (ref_function);
-				cl.ref_function_void = ref_function_void;
+				cl.set_attribute_string ("CCode", "ref_function", ref_function);
+				cl.set_attribute_string ("CCOde", "ref_function_void", ref_function_void);
 			}
 			if (copy_function != null) {
-				cl.set_dup_function (copy_function);
+				cl.set_attribute_string ("CCode", "copy_function", copy_function);
 			}
 			if (unref_function != null) {
-				cl.set_unref_function (unref_function);
+				cl.set_attribute_string ("CCode", "unref_function", unref_function);
 			} else if (free_function != null) {
-				cl.set_free_function (free_function);
+				cl.set_attribute_string ("CCode", "free_function", free_function);
 			}
 
 			current_data_type = null;
@@ -1245,16 +1245,16 @@ public class Vala.GIdlParser : CodeVisitor {
 			}
 
 			if (ref_function != null) {
-				cl.set_ref_function (ref_function);
-				cl.ref_function_void = ref_function_void;
+				cl.set_attribute_string ("CCode", "ref_function", ref_function);
+				cl.set_attribute_string ("CCOde", "ref_function_void", ref_function_void);
 			}
 			if (copy_function != null) {
-				cl.set_dup_function (copy_function);
+				cl.set_attribute_string ("CCode", "copy_function", copy_function);
 			}
 			if (unref_function != null) {
-				cl.set_unref_function (unref_function);
+				cl.set_attribute_string ("CCode", "unref_function", unref_function);
 			} else if (free_function != null) {
-				cl.set_free_function (free_function);
+				cl.set_attribute_string ("CCode", "free_function", free_function);
 			}
 
 			current_data_type = null;



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