The c# docs says that the FirstNode property returns a XNode.
public System.Xml.Linq.XNode FirstNode { get; }
However when i call the GetType() method on it, it says System.Xml.Linq.XElement
For example..
var MyElement = new XElement("Base",
new XElement("FirstName", "John",
new XComment("Thats a cool name")),
new XElement("LastName", "Doe")
);
Console.WriteLine(MyElement.FirstNode.GetType());//System.Xml.Linq.XElement
Further more, It doesnt have the methods which apply to XElements like the property FirstNode itself.
Can someone explain what is going on.