BEGIN { no strict 'refs'; for my $property (qw/id debug display_time default_text/) { *$property = sub : lvalue { $_[0]->{$property} }; } }