XML Schema Part 2: Datatypes Second Edition:
3.2.15.2 Canonical Representation
The canonical representation for hexBinary is defined by prohibiting
certain options from the Lexical Representation (ยง3.2.15.1).
Specifically, the lower case hexadecimal digits ([a-f]) are not allowed.
XML::Compile generates lower case hexadecimal digits.
This is important bug because some other tools doesn't expect lower case
hexadecimal digits and might not accept XML produced by
XML::Compile::Schema
Patch:
--- BuiltInTypes.pm.orig 2011-12-09 14:41:27.376040124 +0100
+++ BuiltInTypes.pm 2011-12-09 14:36:45.528206819 +0100
@@ -301,7 +301,7 @@
# (Use of) an XS implementation would be nice
$builtin_types{hexBinary} =
{ parse => sub { $_[0] =~ s/\s+//g; pack 'H*', $_[0]}
- , format => sub { unpack 'H*', $_[0]}
+ , format => sub { uc unpack 'H*', $_[0]}
, check =>
sub { $_[0] !~ m/[^0-9a-fA-F\s]/ && (($_[0] =~ tr/0-9a-fA-F//)
%2)==0}
, example => 'F00F'