From: Dave Rolsky Date: Sat, 25 Sep 2010 19:48:50 +0000 (-0500) Subject: Make sure accessor's writer side does what the writer code does X-Git-Tag: 1.15~93 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=dc7a289785914bce20545f7eb71dcfacffb05ef1;p=gitmo%2FMoose.git Make sure accessor's writer side does what the writer code does --- diff --git a/lib/Moose/Meta/Method/Accessor/Native/Array/accessor.pm b/lib/Moose/Meta/Method/Accessor/Native/Array/accessor.pm index cc5d244..a419410 100644 --- a/lib/Moose/Meta/Method/Accessor/Native/Array/accessor.pm +++ b/lib/Moose/Meta/Method/Accessor/Native/Array/accessor.pm @@ -45,7 +45,7 @@ sub _generate_method { $code .= "\n" . '} else {'; $code .= "\n" . $self->_inline_check_argument_count; - + $code .= "\n" . $self->_inline_process_arguments( $inv, $slot_access ); $code .= "\n" . $self @@ -53,6 +53,7 @@ sub _generate_method { my $potential_value = $self->_potential_value($slot_access); + $code .= "\n" . $self->_inline_copy_value( \$potential_value ); $code .= "\n" . $self->_inline_tc_code( $potential_value,