[PATCH] guile-readline: Use an empty string if HOME is unset

2014-09-10 Thread David Michael
* guile-readline/ice-9/readline.scm (history-file): When the HOME environment variable is unset, use the empty string in its place. --- Hi, If a Guile program uses the readline module without setting HOME, it will fail due to string-append getting a #f argument. In particular, this necessitate

Streams and gc

2014-09-10 Thread Stefan Israelsson Tampe
Consider getting a stream of data and that we store it through consing, this has the drawback that the list will grow indefinitely. What you want is to make sure that any data that you need for computation a pointer to the start and end of the data would mean that by modding the mark procedure wil

Re: [PATCH] guile-readline: Use an empty string if HOME is unset

2014-09-10 Thread Eli Zaretskii
> From: David Michael > Date: Tue, 09 Sep 2014 17:28:42 -0400 > > -(define-once history-file (string-append (getenv "HOME") "/.guile_history")) > +(define-once history-file > + (string-append (or (getenv "HOME") "") "/.guile_history")) Is there any guarantee that the root directory will be writ

Re: [PATCH] guile-readline: Use an empty string if HOME is unset

2014-09-10 Thread David Michael
On Wed, Sep 10, 2014 at 1:00 PM, Eli Zaretskii wrote: >> From: David Michael >> Date: Tue, 09 Sep 2014 17:28:42 -0400 >> >> -(define-once history-file (string-append (getenv "HOME") "/.guile_history")) >> +(define-once history-file >> + (string-append (or (getenv "HOME") "") "/.guile_history"))

Re: [PATCH] guile-readline: Use an empty string if HOME is unset

2014-09-10 Thread Eli Zaretskii
> Date: Wed, 10 Sep 2014 14:06:15 -0400 > From: David Michael > Cc: guile-devel@gnu.org > > > How about "./.guile_history" instead? > > That is okay with me. Do you want a new patch with s/""/"."/ and > s/empty string/current directory/? Please wait for others to chime in. I'm not speaking fo

implementation idea for infinite cons lists aka scon(e)s lists.

2014-09-10 Thread Stefan Israelsson Tampe
#| Basically a stream is [x,y,z,...] But we want to gc the tail of the stream if not reachable. How to do this? Well consider a cons cell of [tag,car,cdr] and that the tag can be marked or not just as with the marking of guile-log's logical variables. The technique to create persistant parts of