Created
July 9, 2013 06:40
-
-
Save rjattrill/5955171 to your computer and use it in GitHub Desktop.
Data::Dump - warning on dynamic class with '=' in name Can't handle >Table2|t2=HASH data at c:/opt/strawberry/perl/vendor/lib/Data/Dump.pm line 377.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use Test::Most; | |
use v5.10; | |
use Data::Dumper; | |
use Data::Dump qw(dump); | |
my $dynamic_name = 'Table1|t1<=>Table2|t2'; | |
package Bar { | |
sub new { | |
my $class = shift; | |
bless({}, $class); | |
} | |
}; | |
package Table { | |
sub new { | |
my $class = shift; | |
my $class_name = $class . '::' . $dynamic_name; | |
bless({}, $class_name); | |
} | |
} | |
my $bar = Bar->new(); | |
isa_ok($bar, 'Bar'); | |
my $table = Table->new(); | |
isa_ok($table, "Table::$dynamic_name"); | |
say "table dumper " . Dumper $table; | |
say "table dump " . dump $table; | |
done_testing; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment