[vala] codegen: Use destroy_value in method calls



commit 578f01df8780f4d45603d09e4f0c4895bfca1ceb
Author: Luca Bruno <lucabru src gnome org>
Date:   Wed May 4 11:34:52 2011 +0200

    codegen: Use destroy_value in method calls

 codegen/valaccodemethodcallmodule.vala |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/codegen/valaccodemethodcallmodule.vala b/codegen/valaccodemethodcallmodule.vala
index f7abf5e..ce45393 100644
--- a/codegen/valaccodemethodcallmodule.vala
+++ b/codegen/valaccodemethodcallmodule.vala
@@ -771,7 +771,7 @@ public class Vala.CCodeMethodCallModule : CCodeAssignmentModule {
 
 			if (requires_destroy (arg.value_type)) {
 				// unref old value
-				ccode.add_expression (get_unref_expression (get_cvalue (unary.inner), unary.inner.value_type, unary.inner));
+				ccode.add_expression (destroy_value (unary.inner.target_value));
 			}
 
 			// assign new value



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