xml requires you to specify a root element. in your first example, the point tag is interpreted as the root element. in the second example, point appears twice and can no longer be interpreted as the root element. enclosing both point tags in a root tag will make your example xml-compliant.