* PDCAWLEY via RT (bug-XML-Compile@rt.cpan.org) [120223 07:36]:
Show quoted text> Thu Feb 23 02:36:12 2012: Request 75235 was acted upon.
> Transaction: Ticket created by PDCAWLEY
> Queue: XML-Compile
> Subject: Elements in the VMWare cloud API are uncompileable
> Broken in: 1.19, 1.20, 1.21, 1.22, 1.23, 1.24
>
> cannot find HASH(0x7f8d03448998) as simpleType or complexType
Hi Piers,
This is a bug in a construct which is rarely used, main caused by
a confusing use of variables named "$type". The problem
disappears with this change to XML/Compile/Translate.pm
sub simpleContentRestriction($$)
{ my ($self, $tree) = @_;
...
- my $type;
+ my ($type, $typename);
...
elsif(my $basename = $node->getAttribute('base'))
- { my $typename = $self->rel2abs($where, $node, $basename);
+ { $typename = $self->rel2abs($where, $node, $basename);
...
- $type->{st} = $self->applySimpleFacets($tree, $st, 0, $type);
+ $type->{st} = $self->applySimpleFacets($tree, $st, 0, $typename);
I took the liberty to change your script a bit... ::Cache is more
helpful than ::Schema. Debugging with Test::More is quite hard,
where there are just too many exception catchers around. When it works,
you may wrap it up in Test::More again.
--
Regards,
MarkOv
------------------------------------------------------------------------
Mark Overmeer MSc MARKOV Solutions
Mark@Overmeer.net solutions@overmeer.net
http://Mark.Overmeer.net http://solutions.overmeer.net