[Mono-list] Different behavior when calling XPathSelectElement on a null XElement between Mono 3.10 and .NET/MS-CLR 4.5
mail4dk at gmail.com
Fri Oct 10 16:32:35 UTC 2014
I'm not sure how to call the none Mono CLR so i'll call it .NET 4.5.
I'm not sure how much of an issue is it really but I noticed that the
following code produces different results for me in Mono and in .NET:
XElement element = null;
XElement result = element.XPathSelectElement("missing");
if (result != null)
In .NET 4.5 this produces a System.ArgumentNullException as the argument
passed to the extension method XPathSelectElement is null.
In Mono 3.10 the call to XPathSelectElement returns null which then
continues execution and as a result code that runs fine on Mono throws on
If it helps I'm running Mono version 3.10.0 compiled from source on
Is it really an issue or is so by design?
Should I open a bug for it and if so what should I include or is this
discrepancy should be tolerated?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Mono-list