From: Mark Hubbart Date: 2004-05-08T03:09:15+09:00 Subject: Re: class_missing ? On May 7, 2004, at 9:58 AM, Elias Athanasopoulos wrote: > Hello! > > Is there something similar to method_missing for classes? > > I.e. overload a method of Object or handle an exception > when a 'Foo.new' is called and class Foo does not exist. Something like this? def Object.const_missing(sym) Object.const_set( sym, Class.new() ) end ==>nil Foo.new ==># Bar.new ==># Baz.new ==>#