summaryrefslogtreecommitdiff
path: root/include/ruby/internal/intern/class.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/ruby/internal/intern/class.h')
-rw-r--r--include/ruby/internal/intern/class.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/ruby/internal/intern/class.h b/include/ruby/internal/intern/class.h
index 60baf98472..835e85c26d 100644
--- a/include/ruby/internal/intern/class.h
+++ b/include/ruby/internal/intern/class.h
@@ -175,6 +175,19 @@ VALUE rb_mod_include_p(VALUE child, VALUE parent);
VALUE rb_mod_ancestors(VALUE mod);
/**
+ * Queries the class's descendants. This routine gathers classes that are
+ * subclasses of the given class (or subclasses of those subclasses, etc.),
+ * returning an array of classes that have the given class as an ancestor.
+ * The returned array does not include the given class or singleton classes.
+ *
+ * @param[in] klass A class.
+ * @return An array of classes where `klass` is an ancestor.
+ *
+ * @internal
+ */
+VALUE rb_class_descendants(VALUE klass);
+
+/**
* Generates an array of symbols, which are the list of method names defined in
* the passed class.
*