[Mono-list] Little monodis patch

Jackson Harper jackson@latitudegeo.com
09 Mar 2003 10:24:20 -0800


--=-xgi5w+q8GhaEVK2sFod+
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

Hello,

	Here is a little patch for monodis. This patch makes implements appear
comma seperated instead of with a new implements clause. ie:

	implements Wilma, Betty

	insteadof:

	implements Wilma
	implements Betty

May I commit?

Jackson

-- 
Jackson Harper <jackson@latitudegeo.com>

--=-xgi5w+q8GhaEVK2sFod+
Content-Disposition: attachment; filename=main.c.patch
Content-Type: text/x-patch; name=main.c.patch; charset=UTF-8
Content-Transfer-Encoding: 7bit

Index: main.c
===================================================================
RCS file: /cvs/public/mono/mono/dis/main.c,v
retrieving revision 1.78
diff -u -r1.78 main.c
--- main.c	29 Jan 2003 07:17:34 -0000	1.78
+++ main.c	9 Mar 2003 18:23:50 -0000
@@ -702,6 +702,7 @@
 {
 	plocator_t loc;
 	guint start;
+	gboolean first_interface = 1;
 	guint32 cols [MONO_INTERFACEIMPL_SIZE];
 	char *intf;
 	MonoTableInfo *table = &m->tables [MONO_TABLE_INTERFACEIMPL];
@@ -731,7 +732,12 @@
 		if (cols [MONO_INTERFACEIMPL_CLASS] != loc.idx)
 			break;
 		intf = get_typedef_or_ref (m, cols [MONO_INTERFACEIMPL_INTERFACE]);
-		fprintf (output, "  \timplements %s\n", intf);
+		if (first_interface) {
+		  fprintf (output, "  \timplements %s", intf);
+		  first_interface = 0;
+		} else {
+		  fprintf (output, ", %s", intf);
+		}
 		g_free (intf);
 		++start;
 	}

--=-xgi5w+q8GhaEVK2sFod+--