[Mono-dev] [PATCH] Patch for XmlElement.Prefix

Vorobiev Maksim MVorobiev at croc.ru
Mon Dec 26 08:38:35 EST 2005


Good day.
 
There is another incompatibitily of Mono and MS.NET. This time it's in the details of implementation for XmlElement.Prefix propertie - in set_Prefix method. These differences are:
1. Mono implementation doesn't allow to set String.Empty for prefix - it throws Exception, that value is not NCName. MS just set void prefix for element. I've attached test case for it: "xmlvalid.exe prefix-example.exe" runs on .NET and fails for Mono. Attached patch fixes it.
2. In case of read-only element, ArgumentException should be fired (as noted in MSDN), but not it's XmlException throws. I've changed it also.
3. In case of null value passed to set_Prefix, .NET throws ArgumentNullException, but Mono throws NullReferenceException. This is fixed too.
 
Please somebody, review XmlElement.cs.diff patch and if it's Ok, submit in SVN.
 
Thank you.
 
Воробьев Максим, Компания "Крок"
тел. (+095) 974-22-74 (внутр. 2207)
http://www.croc.ru <http://www.croc.ru/> 
mvorobiev at croc.ru
 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20051226/9dcaf355/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: XmlElement.cs.diff
Type: application/octet-stream
Size: 338 bytes
Desc: XmlElement.cs.diff
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20051226/9dcaf355/attachment.obj 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: xmlvalid.zip
Type: application/x-zip-compressed
Size: 1886 bytes
Desc: xmlvalid.zip
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20051226/9dcaf355/attachment.bin 


More information about the Mono-devel-list mailing list