in reply to [SOLVED] XML::Twig - '#CDATA' attribute in hashref disappears after first call to XML::Twig::Elt->new()

Is this supposed to happen? I did not see anything mentioning this in the CPAN docs... spoilers

Sure, why not? Its constructor, it does what it wants , with the stuff you give it , and with the stuff it gives you

spoiler spoiler spoiler

Yeah spoiler tags are for spoilers, not to hide your questions

  • Comment on Re: XML::Twig - '#CDATA' attribute in hashref disappears after first call to XML::Twig::Elt->new()

Replies are listed 'Best First'.
Re^2: XML::Twig - '#CDATA' attribute in hashref disappears after first call to XML::Twig::Elt->new()
by Anonymous Monk on Jul 21, 2018 at 05:13 UTC
    my $uc_element = XML::Twig::Elt->new('uc_key', {%$attributes}, uc $text);