[Mono-dev] utf8 related patches. Please review.

Mike V vernish13 at gmail.com
Tue Aug 19 12:52:35 EDT 2008


Attached are multiple patches for utf8 functionality.  Please review.

-----------------------------
utf8_additions.patch
-----------------------------
Adds Implementations & Tests to eglib for :
-g_utf8_strlen
-g_utf8_get_char
-g_utf8_next_char

Adds tests for g_utf8_validate, which fail on eglib but pass on glib, more
on this below.

--------------------------
utf8_validate.patch
--------------------------
Adds a new implementation of g_utf8_validate to eglib.  This will fix the
eglib test failures above.

--------------------------
mono_utils.patch
--------------------------
Adds a function requested by Kumpera to combine the functionality of
g_utf8_validate and g_utf8_strlen.

-------------------------
utf8_fulltest.c
-------------------------
A stand alone test program to test all of my functions included in these
patches. It compares my function results to glib's across all valid and
invalid utf8 values.  i.e. 0x00000000 to 0xFFFFFFFF.  My results match
glib's across the whole range.  The program also tests the current
g_utf8_validate function in eglib to show that it has a significant number
of differences with glib.

Kumpera and I are not sure on the best approach for including these tests
into the eglib tests.  The test is very time consuming, and I personally
don't think putting it into the existing eglib test suite is the best idea.
Not to mention it doesn't exactly fit the existing eglib test suite model
since it compares eglib to glib.  Any suggestions would be much appreciated.

To compile > gcc utf8_fulltest.c -I/usr/include/glib-2.0
-I/usr/lib/glib-2.0/include -L/usr/lib -lglib-2.0


Mike Voorhees
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20080819/aec37db6/attachment-0001.html 
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: utf8_fulltest.c
Url: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20080819/aec37db6/attachment-0001.c 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: utf8_validate.patch
Type: application/octet-stream
Size: 3918 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20080819/aec37db6/attachment-0003.obj 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: utf8_additions.patch
Type: application/octet-stream
Size: 9286 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20080819/aec37db6/attachment-0004.obj 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mono_utils.patch
Type: application/octet-stream
Size: 3796 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20080819/aec37db6/attachment-0005.obj 


More information about the Mono-devel-list mailing list