On Wed, Sep 24, 2008 at 03:21:36AM +0900, Charles Oliver Nutter wrote:
> The move to discuss and possibly add this now is motivated by the ugly  
> subclasses_of method in Rails, which uses ObjectSpace and  
> singleton/metaclass tricks to speed up the search for a specific set of  
> subclasses. The fast version of that logic does not work in JRuby  
> without ObjectSpace enabled.

I'm unclear why this couldn't be implemented using #inherited.

One concern I have with Class#subclasses is that it could potentially
prevent anonymous subclasses from being garbage collected, if not
carefully implemented.

I think the utility of this function is clear, though; it would be
useful for more than just Rails.

Paul