use Test::More;
use Data::Dumper;
{
package LD::Person;
use Moo;
use Types::Standard qw/Str ArrayRef InstanceOf/;
use MooX::JSON_LD 'Person';
has name => (
is => 'ro',
json_ld => 'name',
);
has children => (
is => 'ro',
json_ld => 'children',
);
no Moo;
no MooX::JSON_LD;
}
my $c = LD::Person->new( name => 'Carla Foo');
my $p = LD::Person->new( name => 'Sam Foo', children => $c);
diag $p->json_ld;
done_testing;
Causes the script to hang on the json_ld call. This only affects JSONLD objects that contain instances of the same type (in this case LD::Person).
$ = MooX::Role::JSON_LD::json_ld_data(ref(LD::Person)) called from file `lib/perl5/site_perl/5.10.1/MooX/Role/JSON_LD.pm' line 189
$ = MooX::Role::JSON_LD::_resolve_nested(ref(LD::Person)) called from file `lib/perl5/site_perl/5.10.1/MooX/Role/JSON_LD.pm' line 213
@ = MooX::Role::JSON_LD::json_ld_data(ref(LD::Person)) called from file `lib/perl5/site_perl/5.10.1/MooX/Role/JSON_LD.pm' line 240
@ = MooX::Role::JSON_LD::json_ld(ref(LD::Person)) called from file `./ld3.pl' line 24
Running the following code:
Causes the script to hang on the json_ld call. This only affects JSONLD objects that contain instances of the same type (in this case LD::Person).