Hello fellas.

I stumbled into annoying problem. When I deserializing my XML, I am getting
integers as Perl integers, while anything what's sloppy_floats became
strings. (And yes I have that enabled)
To patch that i just altered sloppy_float type translation in
XML::Compile::Schema::BuiltInTypes
like this
295 $builtin_types{sloppy_float} =
296  {
297     parse => sub { $_[0] + 0.0 },
298     check => sub {
299       my $v = eval {use warnings FATAL => 'all'; $_[0] + 0.0};
300       $@ ? undef : 1;
301     }
302  , example => '3.1415'
303  , extends => 'anyAtomicType'
304  };

look at 297 line.

And it's works. Any chance it's getting patched in mainstream?

-- 
Pavel S. Khmelinsky <[email protected]>
Jabber: [email protected]
Skype: hmepas
_______________________________________________
Xml-compile mailing list
[email protected]
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/xml-compile

Reply via email to