diff options
author | Daniel Martin <consume.noise@gmail.com> | 2013-08-18 15:18:10 +0200 |
---|---|---|
committer | Daniel Martin <consume.noise@gmail.com> | 2013-08-25 11:22:20 +0200 |
commit | cb2fa837ffada5d1a682749c40dbdaf28b6a442c (patch) | |
tree | 055fa1d5e08c8ce4600c3e58b1dec21001b71b0c | |
parent | a702f7e1ca7206af4bd5ea23196707b9c7aae236 (diff) |
Enforce a bit or value in enum items
Do not allow enum items without an explicit bit or value. The value of
an enum item is known when adding the enum to the xml specification.
There's no reason why this information shouldn't be where it belongs to.
Signed-off-by: Daniel Martin <consume.noise@gmail.com>
Reviewed-by: Ran Benita <ran234@gmail.com> (and tested)
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
-rw-r--r-- | src/xcb.xsd | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/xcb.xsd b/src/xcb.xsd index 819495b..7a9c800 100644 --- a/src/xcb.xsd +++ b/src/xcb.xsd @@ -353,7 +353,10 @@ authorization from the authors. <xsd:sequence minOccurs="1" maxOccurs="unbounded"> <xsd:element name="item"> <xsd:complexType> - <xsd:group ref="expression" minOccurs="0" maxOccurs="1" /> + <xsd:choice minOccurs="1" maxOccurs="1"> + <xsd:element name="value" type="dec-or-hex-integer" /> + <xsd:element name="bit" type="xsd:integer" /> + </xsd:choice> <xsd:attribute name="name" type="xsd:string" use="required" /> </xsd:complexType> </xsd:element> |