Re: Setting namespace in loaded files
- From: khaines@xxxxxxxxx
- Date: Wed, 23 Aug 2006 04:03:34 +0900
On Wed, 23 Aug 2006, Luke Kanies wrote:
If you read the file, and then eval it in the desired scope, it has the effect of loading it into that scope.
Hmmm. That complicates things a little, since I need to iterate through $: myself, but it seems like about the only way.
It can be made to work. I do a lot of this sort of dynamic loading with no problems. Write yourself a method that iterates through your search path, and write one that loads and evals a file into a specific scope, and it should come together all right for you.
Kirk Haines
.
- References:
- Setting namespace in loaded files
- From: Luke Kanies
- Re: Setting namespace in loaded files
- From: khaines
- Re: Setting namespace in loaded files
- From: Luke Kanies
- Setting namespace in loaded files
- Prev by Date: Re: How to search Ruby files in Windows
- Next by Date: Re: Static typing ain't so bad, after all...
- Previous by thread: Re: Setting namespace in loaded files
- Next by thread: Re: Setting namespace in loaded files
- Index(es):
Relevant Pages
|