From: marcandre-ruby-core@... Date: 2020-12-07T21:06:21+00:00 Subject: [ruby-core:101294] [Ruby master Bug#17374] Refined methods aren't visible from a refinement's module Issue #17374 has been updated by marcandre (Marc-Andre Lafortune). jeremyevans0 (Jeremy Evans) wrote in #note-6: > This is because `refine` implicitly activates the refinement, so the refinement is active at the point `bar` is called. This approach works back to Ruby 2.0, with output: > > ``` > :none > :none > 42 > ``` Thanks for trying it out. This is not the desired output, though. The last `using` has no effect. Desired output is: ``` :none # No refinement active yet 42 # using was activated 42 # extend works too (assuming the `using` part is commented out... ``` My understanding is that the `refine` simply has no effect, since the module is empty at that point, no? ---------------------------------------- Bug #17374: Refined methods aren't visible from a refinement's module https://bugs.ruby-lang.org/issues/17374#change-88978 * Author: marcandre (Marc-Andre Lafortune) * Status: Open * Priority: Normal * Assignee: shugo (Shugo Maeda) * Backport: 2.5: UNKNOWN, 2.6: UNKNOWN, 2.7: UNKNOWN ---------------------------------------- -- https://bugs.ruby-lang.org/ Unsubscribe: