Elizabeth Mattijsen wrote:At 6:45 AM +0000 4/7/05, Rafael Garcia-Suarez wrote:
Stas Bekman wrote in perl.perl5.porters : > It's time to write CLONE2 which should be a method, identical to DESTROY,
which should be called by perl_clone(), when it sees that the
> object->can('CLONE2'). Names that match /^\w+\d+$/ suck. What about "OBJCLONE", "INSTCLONE" or something else that indicates that it's the instance version ?
This discussion has happened many time before in the past years. It was felt that a method being called on each object at clone time was simply too much. That's why I made Thread::Bless.
If Thread::Bless does not do what you need, please let me know how I can fix that.
The advantage would be that you wouldn't need blead to run a threaded mod_perl2, right?
1) I already do what Thread::Bless does and in the complicated environment like mod_perl2 it's very inefficient,
Probably.
.. and so far there are lots of segfaults. The reason for segfaults might be different, but I want first to eliminate the hack. So only the cloning part will be left to deal with.
I'm surprised by the segfaults you're seeing...
2) I need to do it in C - it must be absolutely transparent to users.
But you're forcing threaded mod_perl2 users to have to use blead this way, or?
Liz
