[Mono-bugs] [Bug 22980] Changed - Split method does not work

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
3 Apr 2002 08:44:57 -0000


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by contact@christophe.vg.

http://bugzilla.ximian.com/show_bug.cgi?id=22980

--- shadow/22980	Wed Apr  3 03:43:59 2002
+++ shadow/22980.tmp.28077	Wed Apr  3 03:44:57 2002
@@ -35,6 +35,41 @@
 RESULT: 0
 
 ------- Additional Comments From lupus@ximian.com  2002-04-03 03:43 -------
 
 
 *** This bug has been marked as a duplicate of 22795 ***
+
+------- Additional Comments From contact@christophe.vg  2002-04-03 03:44 -------
+It seems this is due to the "params" problem mentioned earlier on the
+list.
+
+class Tester {
+  public static void show( params char[] seps ) {
+    foreach(  char sep in seps ) {
+      System.Console.WriteLine( "sep = {0}", sep );
+    }
+  }
+  public static void show2( char[] seps ) {
+    foreach(  char sep in seps ) {
+      System.Console.WriteLine( "sep = {0}", sep );
+    }
+  }
+  public static void Main() {
+    char[] seps = new char[] { ' ', ',', 'a' };
+    show( seps );
+    System.Console.WriteLine( "----" );
+    show2( seps );
+  }
+
+}
+
+
+[ntt@taurus cs]$ mcs test.cs
+RESULT: 0
+[ntt@taurus cs]$ mono test.exe 
+sep =  
+----
+sep =  
+sep = ,
+sep = a
+RESULT: 0