Well, I dont support Dumper style variable naming, I do a Dump style do{} output instead. But heres your two cases. From what I can tell they come out correctly. Let me know if they are wrong.

UPDATE
Doh. I shouldhave read your bugreport more carefully. Obviously both of these are incorrect in the respect that you mention. But i'm pretty sure that I can resolve that. Ill let you know.

Oh and thanks, I've been meaning to get the Dumper test cases and run them through BFDump, but keep forgetting. So now that I've been reminded the download is running... ;-)

use Data::BFDump qw(BFDump); my @dogs = ( 'Fido', 'Wags' ); my %kennel = ( First => \$dogs[0], Second => \$dogs[1], ); $dogs[2] = \%kennel; my $mutts = \%kennel; print "BFDump(\\\@dogs, \\\%kennel, \$mutts);\n"; print BFDump(\@dogs, \%kennel, $mutts),"\n\n"; print "BFDump(\\\%kennel, \\\@dogs, \$mutts);\n"; print BFDump(\%kennel, \@dogs, $mutts),"\n"; __END__ BFDump(\@dogs, \%kennel, $mutts); do { my $RT_ARRAY = [ 'Fido', 'Wags', {} ]; my $RT_HASH = { First => \do { my $v = 'Fido' }, Second => \do { my $v = 'Wags' } }; $RT_ARRAY->[2] = $RT_HASH; ( $RT_ARRAY, $RT_HASH, $RT_HASH ) } BFDump(\%kennel, \@dogs, $mutts); do { my $RT_HASH = { First => \do { my $v = 'Fido' }, Second => \do { my $v = 'Wags' } }; my $RT_ARRAY = [ 'Fido', 'Wags', $RT_HASH ]; ( $RT_HASH, $RT_ARRAY, $RT_HASH ) }
Oh and if anyone is wondering what the RT means in the variable names, it stands for root.

Yves / DeMerphq
---
Writing a good benchmark isnt as easy as it might look.


In reply to Re: •Re: Reinventing the wheel: Dumper Difficulties by demerphq
in thread Reinventing the wheel: Dumper Difficulties by demerphq

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.