difforig B-LexInfo
diff -u B-LexInfo/LexInfo.pm.orig
--- B-LexInfo/LexInfo.pm.orig 2008-05-16 16:56:15.015625000 +0000
+++ B-LexInfo/LexInfo.pm 2008-05-16 17:16:45.937500000 +0000
@@ -134,9 +134,9 @@
my $cmd = "$DiffCmd $file_b $file_a";
if ($cmd =~ /^([^<>|;]+)$/) {
$cmd= $1;
- }
+ }
else {
- die "TAINTED data in `$cmd'";
+ die "TAINTED data in `$cmd'";
}
my $pipe = Symbol::gensym();
@@ -213,7 +213,7 @@
my($sv) = @_;
+{ NULL => sprintf "0x%lx", $$sv }
}
-
+
sub B::SPECIAL::lexval {
my($sv) = @_;
+{ SPECIAL => sprintf "0x%lx", $$sv }
@@ -229,8 +229,8 @@
=head1 SYNOPSIS
- use B::ShowLex ();
- my $lexi = B::ShowLex->new;
+ use B::LexInfo ();
+ my $lexi = B::LexInfo->new;
=head1 DESCRIPTION
diff -u B-LexInfo/LexInfo.xs.orig
--- B-LexInfo/LexInfo.xs.orig 2008-05-16 16:56:15.078125000 +0000
+++ B-LexInfo/LexInfo.xs 2008-05-16 16:58:04.453125000 +0000
@@ -4,7 +4,7 @@
typedef SV * B__PV;
-static XS(XS_B__PV_LEN)
+XS(XS_B__PV_LEN)
{
dXSARGS;
@@ -30,7 +30,7 @@
XSRETURN(1);
}
-static XS(XS_B__PV_CUR)
+XS(XS_B__PV_CUR)
{
dXSARGS;
@@ -56,7 +56,7 @@
XSRETURN(1);
}
-static void boot_B_LexInfo(void)
+void boot_B_LexInfo(void)
{
/* these were not present in 5.005_57
* make conditional in case they are added
diff -u B-LexInfo/README.orig
--- B-LexInfo/README.orig 2008-05-16 16:56:15.078125000 +0000
+++ B-LexInfo/README 2008-05-16 17:04:58.140625000 +0000
@@ -2,8 +2,8 @@
B::LexInfo - Show information about subroutine lexical variables
SYNOPSIS
- use B::ShowLex ();
- my $lexi = B::ShowLex->new;
+ use B::LexInfo ();
+ my $lexi = B::LexInfo->new;
DESCRIPTION
Perl stores lexical variable names and values inside a *padlist*
diff -u B-LexInfo/t/02_cvlexinfo.t.orig
--- B-LexInfo/t/02_cvlexinfo.t.orig 2008-05-16 17:19:18.625000000 +0000
+++ B-LexInfo/t/02_cvlexinfo.t 2008-05-16 17:15:08.984375000 +0000
@@ -0,0 +1,13 @@
+#!/usr/bin/env perl -w
+
+use strict;
+use Test;
+BEGIN { plan tests => 1 }
+
+use B::LexInfo;
+my $lexi = B::LexInfo->new;
+my $info = $lexi->cvlexinfo('Data::Dumper::Seen');
+
+ok(1);
+
+__END__
diff -u B-LexInfo/t/03_stash_cvlexinfo.t.orig
--- B-LexInfo/t/03_stash_cvlexinfo.t.orig 2008-05-16 17:19:36.484375000 +0000
+++ B-LexInfo/t/03_stash_cvlexinfo.t 2008-05-16 17:17:44.953125000 +0000
@@ -0,0 +1,15 @@
+#!/usr/bin/env perl -w
+
+use strict;
+use Test;
+BEGIN { plan tests => 1 }
+
+use B::LexInfo;
+my $lexi = B::LexInfo->new;
+my $info = $lexi->stash_cvlexinfo('Data::Dumper');
+ok(1);
+
+exit;
+
+__END__
+
diff -u B-LexInfo/t/04_dumper.t.orig
--- B-LexInfo/t/04_dumper.t.orig 2008-05-16 17:19:36.484375000 +0000
+++ B-LexInfo/t/04_dumper.t 2008-05-16 17:18:29.531250000 +0000
@@ -0,0 +1,13 @@
+#!/usr/bin/env perl -w
+
+use strict;
+use Test;
+BEGIN { plan tests => 1 }
+
+use B::LexInfo;
+my $lexi = B::LexInfo->new;
+my $info = $lexi->stash_cvlexinfo('Data::Dumper');
+ok ($lexi->dumper($info));
+
+__END__
+
diff -u B-LexInfo/t/05_diff.t.orig
--- B-LexInfo/t/05_diff.t.orig 2008-05-16 17:19:36.492375000 +0000
+++ B-LexInfo/t/05_diff.t 2008-05-16 17:12:33.218750000 +0000
@@ -0,0 +1,16 @@
+#!/usr/bin/env perl -w
+
+use strict;
+use Test;
+BEGIN { plan tests => 1 }
+
+use B::LexInfo;
+my $lexi = B::LexInfo->new;
+my $before = $lexi->stash_cvlexinfo('Data::Dumper');
+my $b = Data::Dumper->new([$a], ['c']);
+my $after = $lexi->stash_cvlexinfo('Data::Dumper');
+my $diff = B::LexInfo->diff($before, $after);
+ok ($$diff);
+
+__END__
+
diff -u B-LexInfo/t/06_cvrundiff.t.orig
--- B-LexInfo/t/06_cvrundiff.t.orig 2008-05-16 17:19:41.984375000 +0000
+++ B-LexInfo/t/06_cvrundiff.t 2008-05-16 17:14:20.500000000 +0000
@@ -0,0 +1,20 @@
+#!/usr/bin/env perl -w
+
+use strict;
+use Test;
+BEGIN { plan tests => 1 }
+
+package Foo;
+use B::LexInfo ();
+
+sub bar {
+ my($string) = @_;
+}
+
+my $lexi = B::LexInfo->new;
+my $diff = $lexi->cvrundiff('Foo::bar', "a string");
+
+ok ($$diff);
+
+__END__
+