(PUP- 2035) loader infrastructure 

This is the first cut of the new loader infrastructure. It currently only deals with loading of functions, and does not yet fully configure loaders to load from modules on the module path.

This PR is for review only (it has a w.i.p commit), and there may be additional things to fix for different ruby versions after this has gone through a travis run.