in reply to Re: When to use prototype inheritence?
in thread When to use prototype inheritence?
You could probably just do:
This would depend on how the classless/prototype system works. (I don't know one well enough to give a full example)my $object = $proto->new(); $object->set(some=>'stuff'); { my $test_object = $object; $test_object->{method} = sub { print "got:".$_[0]->{_proto_}->method() }; $test_object->method(); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: When to use prototype inheritence?
by simonm (Vicar) on Sep 08, 2003 at 16:13 UTC |