note TheDamian <blockquote><i> Whenever your setter needs to be normalized to a different value lvalue accessors don't cut it. </i></blockquote> Well...that certainly <i>used</i> to be the case. Indeed, the fact that you have to employ the complexities of tied proxy variables to retain control when using lvalue accessors, is precisely why I cautioned against lvalue accessors in "Perl Best Practices". <p> But last week I released the latest version of the <a href="">Contextual::Return</a> module, with which you can now hide all the complexity of tied proxies behind <a href="">two simple <c>LVALUE</c>, and <c>RVALUE</c> blocks</a>. For example: <code> use Contextual::Return; # Name method offers unconstrained access... sub name : lvalue { my ($self) = @_; $name_of{ident $self}; } # Rank method constrains access: can assign only valid ranks # (value being assigned is passed as $_ to LVALUE block)... sub rank : lvalue { my ($self) = @_; LVALUE { croak "Invalid rank ($_) assigned" if !$is_valid_rank{$_}; $rank_of{ident $self} = $_; } RVALUE { $rank_of{ident $self}; } } # Serial method offers read-only access... sub serial { my ($self) = @_; return $snum_of{ident $self}; } </code> <p> With this functionality now available, I'm seriously reconsidering my long-held objections to lvalue accessors. <p>Damian 531997 532091