[Mono-bugs] [Bug 480152] string.Normalize() frequently produces incorrect output

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed Jan 20 03:13:10 EST 2010


http://bugzilla.novell.com/show_bug.cgi?id=480152

http://bugzilla.novell.com/show_bug.cgi?id=480152#c5


--- Comment #5 from Alexander Kojevnikov <alexander at kojevnikov.com> 2010-01-20 08:13:08 UTC ---
I have another test case for Korean characters, it's been reported downstream:
https://bugzilla.gnome.org/show_bug.cgi?id=605389

The programme below prints:

ae40 d604 c2dd 
a76f a76f a76f

NET 3.5 SP1 prints:

ae40 d604 c2dd
1100 1175 11b7 1112 1167 11ab 1109 1175 11a8

$ mono -V
Mono JIT compiler version 2.6.1 (tarball Sun Dec 20 16:04:39 CET 2009)
Copyright (C) 2002-2008 Novell, Inc and Contributors. www.mono-project.com
    TLS:           __thread
    GC:            Included Boehm (with typed GC and Parallel Mark)
    SIGSEGV:       altstack
    Notifications: epoll
    Architecture:  amd64
    Disabled:      none

$ uname -rs
Linux 2.6.32-ARCH

Test case:

>>>>>>>>>>>>>>>>>>>>>>>
using System;
using System.Text;

namespace test
{
    class MainClass
    {
        static void Main(string[] args)
        {
            var a = "\uae40\ud604\uc2dd";
            var b = a.Normalize(NormalizationForm.FormKD);
            print(a);
            print(b);
        }

        private static void print(string s)
        {
            foreach(var c in s)
            {
                Console.Write("{0:x} ", (int)c);
            }
            Console.WriteLine();
        }
    }
}
<<<<<<<<<<<<<<<<<<<<<<<<

-- 
Configure bugmail: http://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.


More information about the mono-bugs mailing list