From: Steve Peters Date: Fri, 29 Feb 2008 05:39:42 +0000 (+0000) Subject: Re-apply change #32880 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=f35ac149ccbf0910af5ad0f0addfe08a04f4ceff;p=p5sagit%2Fp5-mst-13.2.git Re-apply change #32880 p4raw-link: @32880 on //depot/perl: 0fc92fc6bbe8a1e6ff117eca89462208ffcf7f5c p4raw-id: //depot/perl@33397 --- diff --git a/lib/Test/Builder.pm b/lib/Test/Builder.pm index 26c2d22..1ccad4f 100644 --- a/lib/Test/Builder.pm +++ b/lib/Test/Builder.pm @@ -3,7 +3,7 @@ package Test::Builder; use 5.006; use strict; -our $VERSION = '0.78'; +our $VERSION = '0.78_01'; $VERSION = eval { $VERSION }; # make the alpha version come out as a number # Make Test::Builder thread-safe for ithreads. @@ -920,7 +920,11 @@ sub maybe_regex { my($re, $opts); # Check for qr/foo/ - if( _is_qr($regex) ) { + if ( $] >= 5.009004 + ? re::is_regexp($regex) + : ref $regex eq 'Regexp' + ) + { $usable_regex = $regex; } # Check for '/foo/' or 'm,foo,'