[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Different dialects under the same root
- To: Vitaly Magerya <vmagerya@xxxxxxxxx>
- Subject: Re: Different dialects under the same root
- From: Derick Eddington <derick.eddington@xxxxxxxxx>
- Date: Fri, 11 Dec 2009 17:43:29 -0800
- Cc: srfi-103@xxxxxxxxxxxxxxxxx
- Delivered-to: srfi-103@xxxxxxxxxxxxxxxxx
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:subject:from:to:cc :in-reply-to:references:content-type:date:message-id:mime-version :x-mailer:content-transfer-encoding; bh=yDHK6MU3brhmXpof7zdTDuDUx7a6FO+YeprxuJnyeKg=; b=Eb5iUFXG8h4QF7nh2NwbNGAm7LngQIst549uuU58ppFJBmcg48n96H0K7ExYl2//oj +zn0OmvwIIXehEQpuySdTZ80fNj1OMoelrePu9SmPR2S8Rm/i06EmtY+Rle4KAM4mvvh 8imPtr+LYaXDcZWDwSR3xbeMH6ylVD8EU4BYU=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:from:to:cc:in-reply-to:references:content-type:date :message-id:mime-version:x-mailer:content-transfer-encoding; b=BeK7qIbdvUeSslUM2qqmFdn8jiTP/HKDtPL9JhCsQNnwN6M+jRlHrhu08K3Fxx6QZ7 dv8iT3LU0mPbEouXDUKsDZjjM2kKgAgIybN4EB3F+5c/t91ePup4AB1mCIpAl5wlxRa/ xXOjs8plqDeV/mofEYotGdJ68NZsxfLtRFDnM=
- In-reply-to: <4B2289BF.4050304@xxxxxxxxx>
- References: <4B226D34.7040506@xxxxxxxxxxx> <4B2289BF.4050304@xxxxxxxxx>
Thank you for the feedback.
On Fri, 2009-12-11 at 20:04 +0200, Vitaly Magerya wrote:
> > Rename R6RS_LIBRARY_PATH to SCHEME_LIB_PATH, because multiple dialects
> > can use this environment variable because they can avoid conflict by
> > using different file name extensions.
> Derick, this change is problematic. Let's say there are two systems:
> Scheme Foo and Scheme Bar, and both of them have library (baz).
I'm not sure if you're saying those two systems implement the same
dialect or different dialects, so I'll address both possibilities.
With the previous revision which didn't support different file name
extensions for different dialects, different dialects could not share
the search paths environment variable because different dialects would
be using the same extension and so a file for one dialect could
unavoidably shadow a file for another dialect. With different
extensions, that problem doesn't exist and different dialects can
share the environment variable.
I address the points you made, below.
> from the fact that putting files from different libraries in the same
> folder defeats the purpose of folders,
This SRFI's search paths supports multiple folders, which allows
having different folders. The purpose of folders is grouping, and
different people have different ideals of how they'd like files
grouped. What I've been imagining is that different dialects will
have separate folders and that same-dialect system-specific files will
be in the same folder, but this SRFI supports doing it differently.
Different dialects don't have to have separate folders, because
different dialects should have different extensions, and so, in the
same folder, conflicts of different-dialect library files are not
possible (but auxiliary file conflicts are possible).
Same-dialect system-specific files can be accomplished by using
separate folders for the different systems, instead of using
system-specific extensions and having system-specific files in the
same folder. This SRFI allows the search paths to be initialized with
additional folders before or after those from SCHEME_LIB_PATH, and so
systems can add system-specific folders in which system-specific
libraries exist. Since that is system-specific, exactly how that is
coordinated is outside this SRFI.
> we will have conflicts if:
> * both implementations of (baz) ship with a README or a LICENSE file;
If the different implementations of (baz) are for the same dialect:
They are necessarily system-specific. If the different
implementations are distributed separately and have files whose names
will conflict if they are placed in the same folder, they can be
placed in different folders to avoid conflict.
If the different implementations of (baz) are for different dialects:
There can be separate folders for different dialects, so that
conflicts are avoided.
> * both implementations of (baz) ship with main.r6rs-lib which is a stub
> to load implementation-specific code.
In this case, the different implementations of (baz) are for the same
dialect (because you said .r6rs-lib), so they are necessarily
system-specific. They can be in the same folder and have different
file names, e.g. /folder/baz/main.foo-r6rs-lib and
/folder/baz/main.bar-r6rs-lib, or they can be in different folders
with the same relative file names, e.g. /foo-folder/baz/main.r6rs-lib