I apply .instance_methods(false) on class String, class Array etc…
I build up an Array for completable methods, and feed this to the
ruby Readline module. This already works fine as is, completion works.
But there is one problem:
Right now I hardcode this. So I have an Array that I have to maintain
on my own and I perhaps missed some core components (I am sloppy and
So here is my question:
- Is there a way to programmatically obtain all corelib constants?
(In particular, I am interested in the major classes/modules that
are part of corelib such as class Hash and so forth, not any sublevel
So that I get an Array such as:
[ String, Float, Object, Hash, Array etc…]