[#104307] Float truncate — Eustáquio Rangel <eustaquiorangel@...>
Hi!
4 messages
2021/06/16
[ruby-core:104404] [Ruby master Feature#14394] Class.descendants
From:
eregontp@...
Date:
2021-06-25 12:37:41 UTC
List:
ruby-core #104404
Issue #14394 has been updated by Eregon (Benoit Daloze). Would be good to add this for 3.1, as it will avoid some pretty expensive heap walks just to get a list of subclasses. ---------------------------------------- Feature #14394: Class.descendants https://bugs.ruby-lang.org/issues/14394#change-92647 * Author: ridiculous (Ryan Buckley) * Status: Assigned * Priority: Normal * Assignee: ko1 (Koichi Sasada) ---------------------------------------- There have been numerous implementations of the method Class.descendants by various gems. However, I can't help but think that this ability should be included in the Ruby language itself. Especially since Ruby already offers the counterpart method Class.ancestors. Would it possible to add a `descendants` class method? -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>