I believe the best solution would go something like this:
o) Implement a 'lib' object that does what -lib does on the command line when banged.
o) Add the feature to the lib object that when it is given pairs of names it maps one name to another. So you could write something like:
[loadbang] | [lib maxlib gauss maxlibgauss] | [lib footils gauss gauss]
I'm not sure to what extent we could change things on the fly, since I'm not sure of how names are looked up internally, but it could be that subsequently sending [coll maxcoll( to the [lib maxlib] object would change the binding dynamically.
We don't really need namespaces, just a way to disambiguate names at load time.
We don't really need namespaces, just a way to disambiguate names at load time.
I find that it shouldn't be too difficult to find names that aren't too common. That would be effective enough. One can just add a prefix (developer's initials or library name or something like that) to all the object's names.
Thomas
i'm not sure i understand. are you talking about building an object
that loads libraries? in my experience, once you have a patch saved with those libraries loaded, you're all done. all you need to do is load that patch. maybe i misunderstand your question.
scott
On 13 Aug 2002, jfm3 wrote:
I believe the best solution would go something like this:
o) Implement a 'lib' object that does what -lib does on the command line when banged.
o) Add the feature to the lib object that when it is given pairs of names it maps one name to another. So you could write something like:
[loadbang] | [lib maxlib gauss maxlibgauss] | [lib footils gauss gauss]
I'm not sure to what extent we could change things on the fly, since I'm not sure of how names are looked up internally, but it could be that subsequently sending [coll maxcoll( to the [lib maxlib] object would change the binding dynamically.
We don't really need namespaces, just a way to disambiguate names at load time.
-- (jfm3 2838 BCBA 93BA 3058 ED95 A42C 37DB 66D1 B43C 9FD0)
"640K ought to be enough for anybody." -- Bill Gates, 1981