From: TRANS Date: 2005-09-27T08:38:04+09:00 Subject: Re: Require Namepaces and RubyGems' effect on LoadPath problem On 9/26/05, Austin Ziegler wrote: > On 9/26/05, TRANS wrote: > > On 9/26/05, Austin Ziegler wrote: > >> Two things. 1. I don't see any particular reason for this. It's neat, > >> but I don't see why it's necessary. 2. If something is loaded from a > >> particular "namespaced" path, that path should remain on the load > >> list, because not everything in a path may actually be loaded with a > >> single require. > > It circumvents the need for a #require_local. > > Um. This is circular. What's the purpose of #require_local? More to the > point, I don't see the point of require_local. It's neat, but > unnecessarily dangerous. Dangerous? > > In doing so it reduces "dependencies" in lib files. What I mean by > > that is I don't have to specify absolute paths in internal lib files. > > If the purpose is less typing, I see even less value. No, it independence from absolutes. WHy does XML have namespaces? Same thing. > [...] > > require 'nano' # adds the namespace > > require 'nano:integer/odd' > > require 'nano:integer/factorial' > > Hm. I don't like it, in any case. It *feels* wrong and unnecessary. Well, feelings are one thing. Do you have any more constructive critisism? I mean I wonder if there's any actual issues wtih this approach --beyond how it feels. > > Finally, it also allows one to organize ones lib directory > > independently of how they are required by the end-user. For instance: > > > > $LOAD_SPACE['somelib'] = %w{ > > somelib/onedir > > somelib/onedir/subdir > > somelib/twodir > > } > > Better would be to just organise your libs intelligently. But that's the point. I'd rather not maintain a single directory with 100+ files? No, I'd rather break them up into some reasonable categories, even though I want the end user to be able access them through one interface. T.