From: eregontp@... Date: 2020-12-19T11:22:38+00:00 Subject: [ruby-core:101537] [Ruby master Misc#17407] Fiber.current and require 'fiber' Issue #17407 has been updated by Eregon (Benoit Daloze). Maybe we should just include these Fiber methods in core, and `require 'fiber'` would be a no-op (for compatibility)? Agreed it's confusing such a core class has only half the documented defined without an extra `require`. ---------------------------------------- Misc #17407: Fiber.current and require 'fiber' https://bugs.ruby-lang.org/issues/17407#change-89319 * Author: zverok (Victor Shepelev) * Status: Open * Priority: Normal ---------------------------------------- Maybe it is not the right time to ask, but why one need to do `require 'fiber'` before using `Fiber.current`? For what I can see, * it is this way since [their introduction](https://docs.ruby-lang.org/en/2.0.0/Fiber.html#method-c-current), * the actual code is defined in the core [cont.c](https://github.com/ruby/ruby/blob/master/cont.c#L2480) * the `ext/fiber.c` [does very little](https://github.com/ruby/ruby/blob/master/ext/fiber/fiber.c) I was just bitten by it again preparing the changelog (stuck with `NoMethodError` and for a few minutes thought the build is broken), is there a reason to have it this way?.. Just clarifying for docs sake, at least. -- https://bugs.ruby-lang.org/ Unsubscribe: