Class: Class
- Inherits:
-
Object
- Object
- Class
- Extended by:
- T::Sig
- Defined in:
- lib/tapioca/core_ext/class.rb
Overview
typed: strict frozen_string_literal: true
Instance Method Summary collapse
Instance Method Details
#descendants ⇒ Object
21 22 23 24 25 26 27 |
# File 'lib/tapioca/core_ext/class.rb', line 21 def descendants result = ObjectSpace.each_object(singleton_class).reject do |k| T.cast(k, Module).singleton_class? || k == self end T.cast(result, T::Array[Class]) end |