vala r1609 - in trunk: . gobject



Author: juergbi
Date: Tue Jun 17 20:26:44 2008
New Revision: 1609
URL: http://svn.gnome.org/viewvc/vala?rev=1609&view=rev

Log:
2008-06-17  JÃrg Billeter  <j bitron ch>

	* gobject/valaccodegenerator.vala:

	Support duplicating errors


Modified:
   trunk/ChangeLog
   trunk/gobject/valaccodegenerator.vala

Modified: trunk/gobject/valaccodegenerator.vala
==============================================================================
--- trunk/gobject/valaccodegenerator.vala	(original)
+++ trunk/gobject/valaccodegenerator.vala	Tue Jun 17 20:26:44 2008
@@ -1280,7 +1280,9 @@
 
 	public CCodeExpression? get_dup_func_expression (DataType type, SourceReference? source_reference) {
 		var cl = type.data_type as Class;
-		if (type.data_type != null) {
+		if (type is ErrorType) {
+			return new CCodeIdentifier ("g_error_copy");
+		} else if (type.data_type != null) {
 			string dup_function;
 			if (type.data_type.is_reference_counting ()) {
 				dup_function = type.data_type.get_ref_function ();



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