-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Reference#exec_recursive[_clone] methods aren't fiber aware
Recursion of the `#inspect` and `#pretty_print` methods is handled by a global hash, which is a per-thread global, but if any of these methods yield —which will happen because they're writing to an IO— another fiber running on the same thread will falsely detect a recursion if it inspects the same object. This patch moves `Reference#exec_recursive` methods as instances of `Fiber`, using a per-fiber hash instead of per-thread/process hash. References #15088
- Loading branch information
1 parent
5a245d9
commit b8ab18c
Showing
2 changed files
with
43 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters