3 # Test || in weird situations.
15 my $instance = shift || undef;
16 return bless \$instance => $class;
20 print "# FETCH! ${$_[0]}\n";
35 my $a_str = sprintf "%s", $a;
36 my $a_num = sprintf "%d", $a;
41 is($c+0, $a_num); # force numeric context.
43 $a =~ /./g or die "Match failed for some reason"; # Make $a magic
48 is($c+0, $a_num); # force numeric context.
55 tie $a, 'Countdown', $val;
58 is($c, 3, 'Single FETCH on tied scalar');
61 is($c, 2, ' $tied = $var');
66 local $TODO = 'Double FETCH';
67 is($c, 1, ' $tied || $var');