diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2006-07-05 21:00:31 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2006-07-05 21:00:31 +0000 |
commit | 461824dcfbc00b3c4e20590f06d6c9881e4a416b (patch) | |
tree | 3552f21bb4637618a680a0d04e52d6de39c5f43b /t | |
parent | f17e6c41cacfbc6fe88a5ea5e01ba690dfdc7f2e (diff) | |
download | perl-461824dcfbc00b3c4e20590f06d6c9881e4a416b.tar.gz |
Implement handling of state variables in list assignment
p4raw-id: //depot/perl@28489
Diffstat (limited to 't')
-rw-r--r-- | t/op/state.t | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/t/op/state.t b/t/op/state.t index 6d09813fe1..31347b1a69 100644 --- a/t/op/state.t +++ b/t/op/state.t @@ -105,7 +105,7 @@ is( gen_cashier()->{bal}->(), 42, '$42 in my drawer' ); # stateless assignment to a state variable sub stateless { - (state $reinitme) = 42; + (state $reinitme, my $foo) = (42, 'bar'); ++$reinitme; } is( stateless(), 43, 'stateless function, first time' ); @@ -151,7 +151,4 @@ sub statelist { my $ls = statelist(); is($ls, "12/23", 'list assignment to state scalars'); $ls = statelist(); -{ - local our $TODO = 'make aassign handle state vars'; - is($ls, "13/24", 'list assignment to state scalars'); -} +is($ls, "13/24", 'list assignment to state scalars'); |