> How is it different from simple tie()ing? For most folks outside P5P tie()ing isn't "simple". In any case this *is* tie()ing, just packaged much more conveniently. > See also > > my Dog $snoopy; > > and PREPARE method. This is orthogonal to typed lexicals. In fact, there's no reason you couldn't: classify my Dog $snoopy => 'Pilot'; Typed lexicals aren't enough on their own. Specifically, they won't stop type-incompatible assignments that introduce subtle bugs: my Dog $snoopy; $snoopy = Alligator->new(); $snoopy->pat(); # unexpected behaviour ;-) $snoopy->{age}++; # maybe *very* unexpected behaviour # E.g: # # package Dog; # use fields qw(name age sex breed); # # package Alligator; # use fields qw(age size weight ID); DamianThread Previous | Thread Next