From: Robert Klemme Date: 2005-04-02T06:24:43+09:00 Subject: Re: Kernel.load() behaviour "Andrew Walrond" schrieb im Newsbeitrag news:200504011904.16688.andrew@walrond.org... > On Friday 01 April 2005 17:24, Robert Klemme wrote: >> >> This has come up recently. Unfortunately there's no chance of getting at >> the anonymous module other than from within the loaded file. I'd wish it >> was changed like this: >> >> Kernel.load(file, mode=nil) >> >> Where "mode" is interpreted like this: >> >> - if it's nil or false, no wrapping takes place, return value is the >> parameter >> >> - if it's a module, that is used for wrapping, return value is the >> module >> >> - if it's anything else (i.e. equivalent to true) an anonymous module is >> created for wrapping, return value is the anonymous module >> >> You might find more on this in the archives. > > Thanks - I'll do a search. >> >> You don't need that: simply wrap the file you want to load with >> >> module Packages >> # all 000s class definitions here >> end >> >> As easy as that. :-) >> > > Not quite; Each of the 000s of packages is in it's own file.... ;) Then I probably misunderstood you. Care to reveal some more details of the design and its rationale? Kind regards robert