]> git.vpit.fr Git - perl/modules/Scope-Upper.git/blobdiff - t/34-localize_elem-magic.t
Protect against d_cplusplus perls
[perl/modules/Scope-Upper.git] / t / 34-localize_elem-magic.t
index 7a99222427567b767d7510b0d9804ef1ad17898e..307db88d298f9544089ab024e0e168a81e719cd1 100644 (file)
@@ -3,7 +3,7 @@
 use strict;
 use warnings;
 
-use Scope::Upper qw/localize_elem UP HERE/;
+use Scope::Upper qw<localize_elem UP HERE>;
 
 use Test::More tests => 8;
 
@@ -20,9 +20,10 @@ use Test::More tests => 8;
 
 our @a;
 
-tie @a, 'Scope::Upper::Test::TiedArray';
 {
- local @a = (5 .. 7);
+ local @a;
+ tie @a, 'Scope::Upper::Test::TiedArray';
+ @a = (5 .. 7);
  {
   localize_elem '@a', 4 => 12 => HERE;
   is_deeply \@a, [ 5 .. 7, undef, 12 ], 'localize_elem @incomplete_tied_array, $nonexistent, 12 => HERE [ok]';