in reply to Question to OO Masters (about Style)

What do you mean by "superposed"? Do you mean that Entry is descended from Dictionary (or vice-versa)? Is that necessary or desired?

What you're describing, though, as other posters mentioned, is perfectly fine from a design point of view.

package Dictionary; ... sub check { my $self = shift; my $error; foreach (@{$self->{children}}) { $error++, last unless $_->check(@_) } return !$error; } package Entry; ... sub check { my $self = shift; return 1 if $self->{value} > 0; # or whatever return; }
If one is a descendent of the other, though, that makes things a little weirder but still workable.