Hi,
Is there any way to _change_ default backend? Something like
Pike.DefaultBackend->replace(MyBackend) - so all subsequent calls to
call_out() and all file descriptors allocated after this will use
new backend?
And more... It would be nice to have dedicated backends in some
threads, so (say) all calls to call_out() and fd's allocation will
use thread-specific backend (if it is set - and default otherwise).
Something like Thread.Thread()->set_backend()...
All this functionality can be simulated(?) - like intercepting
Stdio.File|Stdio.FILE object creation (to use
Backend()->add_file()), call_out()s etc., but it wouldn't be as
clean as "native" support (there is always chance to overlook
something).
As to "Why?" - well, I simply don't want to (over)load single
backend with callbacks from everywhere... Especially when I've SMP
machine - it won't be used efficiently with single backend.
Any comments?
Regards,
/Al