diff --git a/lib/MCE.pm b/lib/MCE.pm index 9eb4c6a..77331e4 100644 --- a/lib/MCE.pm +++ b/lib/MCE.pm @@ -645,7 +645,7 @@ sub spawn { # silently clobbers Perl's srand function, and does not seed Perl's # pseudo-random generator. https://perlmonks.org/?node_id=11159773 - if ( $INC{'PDL/Primitive.pm'} && PDL::Primitive->can('srand') ) { + if ( $INC{'PDL/Primitive.pm'} ) { # Call PDL's random() function if exported i.e. use PDL. my $caller = caller(); local $@; diff --git a/lib/MCE/Child.pm b/lib/MCE/Child.pm index 9bda025..c1b2db8 100644 --- a/lib/MCE/Child.pm +++ b/lib/MCE/Child.pm @@ -115,7 +115,7 @@ sub init { # silently clobbers Perl's srand function, and does not seed Perl's # pseudo-random generator. https://perlmonks.org/?node_id=11159773 - if ( $INC{'PDL/Primitive.pm'} && PDL::Primitive->can('srand') ) { + if ( $INC{'PDL/Primitive.pm'} ) { # Call PDL's random() function if exported i.e. use PDL. my $caller = caller(); local $@;