From: Vincent Pit Date: Fri, 5 Dec 2008 23:25:15 +0000 (+0100) Subject: In t/30-scope.t, avoid failures for "eval 'no indirect; $x = new Foo'" for being... X-Git-Tag: v0.09_01~4 X-Git-Url: http://git.vpit.fr/?p=perl%2Fmodules%2Findirect.git;a=commitdiff_plain;h=993994ae9c31e173043cec3aff1a924bb2694886 In t/30-scope.t, avoid failures for "eval 'no indirect; $x = new Foo'" for being seen as 'more than two warnings' because of an uninitialized $w --- diff --git a/t/30-scope.t b/t/30-scope.t index 414c9c7..f358689 100644 --- a/t/30-scope.t +++ b/t/30-scope.t @@ -43,7 +43,7 @@ sub expect { } { - my $w; + my $w = ''; local $SIG{__WARN__} = sub { $w = 'more than 2 warnings' if $w; $w = join '', 'warn:', @_