Bug 12035 - XmlSchema error with inheritance and nillable elements
Summary: XmlSchema error with inheritance and nillable elements
Alias: None
Product: Class Libraries
Classification: Mono
Component: System.XML ()
Version: unspecified
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: Untriaged
Assignee: Bugzilla
Depends on:
Reported: 2013-04-29 18:07 UTC by David Aramant
Modified: 2013-08-07 12:04 UTC (History)
2 users (show)

Is this bug a regression?: ---
Last known good build:

Sample solution (3.75 KB, application/x-zip-compressed)
2013-04-29 18:07 UTC, David Aramant

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description David Aramant 2013-04-29 18:07:30 UTC
Created attachment 3893 [details]
Sample solution

Mono 3.0.10, Mac OS X 10.8.3

The attached solution contains minimal console program that loads an XML file, a schema, and attempts to validate the file.  On .NET this completes without error, but on Mono the error is:

XmlSchema error: Invalid end element.  There are still required content items.  XML Line 1, Position 276.

The only things remaining in the XML involve inheritance and nillable types.

The code to do the schema checking is fairly ugly, but this it matches what our real application is doing.

We are porting a Windows app to the Mac, which is why the error is reported on the Mac version of Mono.  I have not attempted to reproduce it in Mono on Windows.
Comment 1 Atsushi Eno 2013-08-07 12:04:36 UTC
Fixed in git master [874d3b1].