gen/cpp/config.toml:68-70 maps integer, positive_integer and non_negative_integer all to
int. For example, core::Note::staff() is std::optional<int>, so <staff>0</staff> and
<staff>-3</staff> import with no error and no repair, and a caller can set them. That contradicts
the claim that invalid MusicXML cannot be represented in mx::core.
XSD simple types derived from these, such as staff-number, already have clamping wrappers
(core::StaffNumber). The plain primitives used directly by elements and attributes could get the
same treatment.
Related: #397, #398. Found while auditing silent recoveries for #432 (#439).
gen/cpp/config.toml:68-70mapsinteger,positive_integerandnon_negative_integerall toint. For example,core::Note::staff()isstd::optional<int>, so<staff>0</staff>and<staff>-3</staff>import with no error and no repair, and a caller can set them. That contradictsthe claim that invalid MusicXML cannot be represented in
mx::core.XSD simple types derived from these, such as
staff-number, already have clamping wrappers(
core::StaffNumber). The plain primitives used directly by elements and attributes could get thesame treatment.
Related: #397, #398. Found while auditing silent recoveries for #432 (#439).