Capturing refs causes too many options that can't be worked around
fully. If used in an exception object, one of this module's most common
use cases, capturing objects will keep them alive for as long as the
exception object is alive. This can cause issues with objects that
expect to be DESTROYed at a certain time. Additionally, if thrown
inside a DESTROY sub, the exception object will keep the object being
destroyed alive until after the DESTROY sub finishes. The exception
object will then be freed, and the DESTROY on the object will be called
again.
There is no reliable way to work around those issues, switch to not
capturing by default. Rename the option controlling this from no_refs
to unsafe_ref_capture, but require it to be set true to capture refs.
The previous option will still work if set.
Capturing refs causes too many options that can't be worked around fully. If used in an exception object, one of this module's most common use cases, capturing objects will keep them alive for as long as the exception object is alive. This can cause issues with objects that expect to be DESTROYed at a certain time. Additionally, if thrown inside a DESTROY sub, the exception object will keep the object being destroyed alive until after the DESTROY sub finishes. The exception object will then be freed, and the DESTROY on the object will be called again.
There is no reliable way to work around those issues, switch to not capturing by default. Rename the option controlling this from no_refs to unsafe_ref_capture, but require it to be set true to capture refs. The previous option will still work if set.