[Mono-list] Incompatibility in MONO SelectNodes method

Robert Jordan robertj at gmx.net
Sat Dec 1 21:29:12 EST 2007


Andrus wrote:
> In bug #343960
> 
> https://bugzilla.novell.com/show_bug.cgi?id=343960
> 
> I presented code which works OK in .NET  but crashes in MONO 1.2.6 pvw2.
> Probably SelectNodes() in .NET creates new list but in MONO it does not.
> Atsushi refuses to fix this and marks it INVALID several times.

He explained pretty well why he refused to fix it.

> This is fundamental incompatibility between .NET and MONO XML DOM 
> implementation.

Come on!

> Is it really reasonable not to fix this ?
> 
> How to change this code so it works in MONO also ? 

	XmlNodeList list = xDoc.SelectNodes("//comment()");
	ArrayList temp = new ArrayList ();

	foreach (XmlNode node in list)
		temp.Add (node);
	
	foreach (XmlNode node in temp)
		node.ParentNode.RemoveChild(node);

Robert



More information about the Mono-list mailing list