in reply to Re: Language design: direct attribute access and postponed mutators (Perl Vs Python)
in thread Language design: direct attribute access and postponed mutators (Perl Vs Python)

Thanks, but I think this will be called every time a property is accessed.

That's like tie'ing the underlying blessed hash in Perl, then every read write access to $obj->{attribute} must be handled via FETCH and STORE.

This must slow down OO handling considerably.

The mechanism I described above will only affect especially "enhanced" properties and only when accessed over the external interface.

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery FootballPerl is like chess, only without the dice

  • Comment on Re^2: Language design: direct attribute access and postponed mutators (Perl Vs Python)
  • Download Code