[Mono-bugs] [Bug 459816] New: HashSet.CopyTo not working properly

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed Dec 17 11:00:14 EST 2008


           Summary: HashSet.CopyTo not working properly
           Product: Mono: Class Libraries
           Version: 2.2.x
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: Sys.Core
        AssignedTo: jbevain at novell.com
        ReportedBy: lluis at novell.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---

HashSet.CopyTo does not work when providing an array index > 0.
See the following test case:

using System;
using System.Collections.Generic;

class App
        public static void Main (string[] args)
                HashSet<string> hset = new HashSet<string> ();
                hset.Add ("hi");
                string[] ar = new string[10];
                hset.CopyTo (ar, 1);
                if (ar [1] == null)
                        Console.WriteLine ("Not copied!");

The value added to the HashSet is not copied to the array.

Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

More information about the mono-bugs mailing list