From: Stephen McCamant Date: Sat, 25 May 2002 21:52:16 +0000 (-0700) Subject: B::Deparse: handle blessed code refs in coderef2text X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=0853f1729f6d8a9e9b198ae1cf6f9b5fe7087000;p=p5sagit%2Fp5-mst-13.2.git B::Deparse: handle blessed code refs in coderef2text Message-ID: <15600.27136.853114.694744@soda.csua.berkeley.edu> p4raw-id: //depot/perl@16797 --- diff --git a/ext/B/B/Deparse.pm b/ext/B/B/Deparse.pm index b10c1fb..924f436 100644 --- a/ext/B/B/Deparse.pm +++ b/ext/B/B/Deparse.pm @@ -586,7 +586,7 @@ sub compile { sub coderef2text { my $self = shift; my $sub = shift; - croak "Usage: ->coderef2text(CODEREF)" unless ref($sub) eq "CODE"; + croak "Usage: ->coderef2text(CODEREF)" unless UNIVERSAL::isa($sub, "CODE"); $self->init(); return $self->indent($self->deparse_sub(svref_2object($sub)));