On Thu, 10 Sep 2009 14:03:27 -0400, Brian Mastenbrook <[email protected]> wrote:
> On Thu, 10 Sep 2009 12:45:14 -0500, Andre van Tonder > <[email protected]> > wrote: > >> I'm not sure that is the case. At least in R6 Larceny, you can write >> the >> portable >> >> (import (foo)) >> >> and let the implementation worry about finding the library for you. In >> other words, finding the library is not part of the programmer's >> responsibility. Now, there may be some implementation-specific >> restrictions on >> where you may /put/ the library in the file system, and what you may >> call it, >> but that is not reflected in any way in the syntax of the portable >> program, and >> IMO it is not the place of a spec to really nail this down. > > Sure, I can write (import (foo)) in any implementation, and then also > write a chart of N different methods I need to use to get an > implementation to actually *do* something sensible with that. It's an > unnecessary bother, and I don't think it requires importing all of POSIX > just to talk about generalized notions of "files" and "directories" that > could be used to nail down how the library is found a little bit more. > And > if all else fails, I'd love just to be able to concatenate the libraries > my program requires together with a top-level program and hand the whole > kit-and-kaboodle to my implementation. > > Ultimately the implementation is responsible for reading a top-level > program and its dependent libraries in some fashion, compiling, and > executing the result. Unless the concatenate-the-world solution is > endorsed, they must be separated in some fashion in the input. I don't > think it's too much to speak loosely about directories and files and > leave > the specifics of how that actually works up to the implementation. The > result will be that implementations sharing a platform will do the same > thing where the concepts of "directories" and "files" have clear > definitions, and that your interpretive dancers will have to wear > placards > describing the locations of the libraries they implement. I think it is too much to ask. I don't know of other language standards that do this, except for Java, and I'm not sure we should follow that. And normally, you can just LOAD each library and then you're done. :-) Of course, in Chez you can also concatenate the object files, which is used for distributing the applications, but I don't want to do that for development, I want them to be separate then. So, I use different layouts at different times. Also, Chez doesn't necessarily load the library from the file system if it is already loaded, I like that, and that's a concern if the specification is messed up in a standard. Aaron W. Hsu -- Of all tyrannies, a tyranny sincerely exercised for the good of its victims may be the most oppressive. -- C. S. Lewis _______________________________________________ r6rs-discuss mailing list [email protected] http://lists.r6rs.org/cgi-bin/mailman/listinfo/r6rs-discuss
