Module: PrintMembers::Ext::BasicObject::ClassMethods

Defined in:
lib/print_members/extensions.rb

Class Method Summary collapse

Class Method Details

.boring_classesObject

BasicObject and Object are very boring classes and thus do not consider any other classes to be boring. No, this does not pollute BasicObject. It already inherits the full suite of class methods from Class.



99
100
101
102
103
104
105
# File 'lib/print_members/extensions.rb', line 99

def self.boring_classes
  if self == ::BasicObject || self == ::Object
    super - [self, self.included_modules]
  else
    super   # this will resolve to Module#boring_classes
  end
end