Commits

Toby Inkster  committed b4a3487

Bug fix following Perl v5.18 hash order changes

  • Participants
  • Parent commits 99bfe15

Comments (0)

Files changed (2)

File lib/MooX/Struct.pm

 		if ($self->trace)
 		{
 			require Data::Dumper;
-			my $spec_str = "Data::Dumper"->new([$spec])->Terse(1)->Indent(0)->Dump;
+			my $spec_str = "Data::Dumper"->new([$spec])->Terse(1)->Indent(0)->Sortkeys(0)->Dump;
 			$spec_str =~ s/(^\{)|(\}$)//g;
 			$self->trace_handle->printf(
 				"has %s => (%s);\n",
 is($output, <<"EXPECTED");
 package @{[ Something() ]};
 use Moo;
-has foo => ('isa' => sub { "DUMMY" },'is' => 'ro');
+has foo => ('is' => 'ro','isa' => sub { "DUMMY" });
 sub announce_foo { ... }
 sub FIELDS { ... }
 sub TYPE { ... }