https://bugzilla.novell.com/show_bug.cgi?id=363713


           Summary: Virtual methods of non-sealed Encoding classes should
                    call the same methods that MS.NET calls
           Product: Mono: Class Libraries
           Version: unspecified
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: CORLIB
        AssignedTo: [email protected]
        ReportedBy: [EMAIL PROTECTED]
         QAContact: [email protected]
          Found By: Development


Virtual methods of non-sealed Encoding classes should call the same methods
that MS.NET calls.

You might think that this makes no sense but imagine the following for example:
Someone creates a custom Encoding class and implements int GetByteCount(char[]
chars) using int GetByteCount(char* chars, int count).

This will run without problem on MS.NET because that will call  int
GetByteCount(char[] chars, int index, int count)
 but will result in an infinite recursion on Mono because that calls int
GetByteCount(char[] chars) from int GetByteCount(char* chars, int count).

Note that this is not only an issue with Encodins, this applies to all
non-sealed classes with virtual methods.

The attached test prints the current results.


-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
_______________________________________________
mono-bugs maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-bugs

Reply via email to