Replace no_refs option with unsafe_ref_capture option #6
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.