bug#20087: gensym

2016-06-23 Thread Andy Wingo
On Thu 23 Jun 2016 16:13, l...@gnu.org (Ludovic Courtès) writes: > Andy Wingo skribis: > >> I just pushed something to master to error when serializing an >> uninterned symbol. Otherwise compiling an uninterned symbol effectively >> interns it! I am not sure that we can apply such a fix in 2.0

bug#20087: gensym

2016-06-23 Thread Ludovic Courtès
Andy Wingo skribis: > On Thu 24 Mar 2016 09:45, l...@gnu.org (Ludovic Courtès) writes: > >> Mark H Weaver skribis: >> >>> It turns out the manual already has the following text in the ‘gensym’ >>> entry, which I think is sufficient. >>> >>>

bug#20087: gensym

2016-06-23 Thread Andy Wingo
On Thu 24 Mar 2016 09:45, l...@gnu.org (Ludovic Courtès) writes: > Mark H Weaver skribis: > >> It turns out the manual already has the following text in the ‘gensym’ >> entry, which I think is sufficient. >> >> The symbols generated by ‘gensym’ are _likely_

bug#20087: gensym

2016-03-24 Thread Ludovic Courtès
;> hope for is to significantly reduce the probability of _unintentional_ >>> collisions, perhaps by starting the gensym counter at a large number. >> >> I’m not sure if that would help. >> >> One thing that could help avoid unintentional collisions is to >> automa

bug#20087: gensym

2016-03-23 Thread Mark H Weaver
ility of _unintentional_ >> collisions, perhaps by starting the gensym counter at a large number. > > I’m not sure if that would help. > > One thing that could help avoid unintentional collisions is to > automatically add whitespace before the number, such that: > > (gensym &quo

bug#20087: gensym

2016-03-22 Thread Mark H Weaver
ra...@openmailbox.org writes: > On 2016-03-22 05:24, Mark H Weaver wrote: >> l...@gnu.org (Ludovic Courtès) writes: >>> ‘gensym’ returns interned symbols, but the algorithm to determine the >>> new symbol is simplistic and predictable. >>> >>> Thu

bug#20087: gensym

2016-03-22 Thread rain1
On 2016-03-22 05:24, Mark H Weaver wrote: l...@gnu.org (Ludovic Courtès) writes: ‘gensym’ returns interned symbols, but the algorithm to determine the new symbol is simplistic and predictable. Thus, one can arrange to produce a symbol before ‘gensym’ does, leading ‘gensym’ to return a symbol

bug#20087: gensym

2016-03-22 Thread Ludovic Courtès
Mark H Weaver skribis: > I've considered this idea in the past, but it only avoids collisions > with symbols that have been interned before the gensym. It does not > avoid collisions with symbols interned *after* the gensym. Obviously, > there's no way to avoid such c

bug#20087: gensym

2016-03-21 Thread Mark H Weaver
l...@gnu.org (Ludovic Courtès) writes: > ‘gensym’ returns interned symbols, but the algorithm to determine the > new symbol is simplistic and predictable. > > Thus, one can arrange to produce a symbol before ‘gensym’ does, leading > ‘gensym’ to return a symbol that’s not fresh (

bug#20087: gensym

2016-03-18 Thread rain1
Hello I agree, this goes against the main assumption people have about gensym. I was able to reproduce the bug. Here's a patch to libguile/symbol.c which fixes this behavior by incrementing the gensym counter in a loop until it creates a fresh symbol. diff --git a/libguile/symbol

bug#20087: 'gensym' is not guaranteed to return a fresh symbol

2015-03-11 Thread Ludovic Courtès
‘gensym’ returns interned symbols, but the algorithm to determine the new symbol is simplistic and predictable. Thus, one can arrange to produce a symbol before ‘gensym’ does, leading ‘gensym’ to return a symbol that’s not fresh (in terms of ‘eq?’), as is the case with the second call to ‘gensym

[bugs #8596] srfi-11 uses gentemp instead of gensym

2004-12-05 Thread Kevin Ryde
None Status: Closed Summary: srfi-11 uses gentemp instead of gensym Original Submission: This causes a deprecation warning in code that uses let-values. Fix is trivial (substitute with gensym). Follow-up Comments -- ---

[bugs #8596] srfi-11 uses gentemp instead of gensym

2004-04-17 Thread Kevin Ryde
.gnu.org/bugs/?func=detailitem&item_id=8596> Project: Guile Submitted by: Andreas Rottmann On: Fri 04/16/04 at 18:29 Category: None Severity: 5 - Average Item Group: None Resolution: Fixed Assigned to: None Status: Open Summary: srfi-11 uses gentemp instead of gensym Original

[bugs #8596] srfi-11 uses gentemp instead of gensym

2004-04-16 Thread Andreas Rottmann
bmitted by: Andreas Rottmann On: Fri 04/16/04 at 18:29 Category: None Severity: 5 - Average Item Group: None Resolution: None Assigned to: None Status: Open Summary: srfi-11 uses gentemp instead of gensym Original Submission: This causes a deprecation warning in code that uses let-value

[bugs #8596] srfi-11 uses gentemp instead of gensym

2004-04-16 Thread Andreas Rottmann
bmitted by: Andreas Rottmann On: Fri 04/16/04 at 18:29 Category: None Severity: 5 - Average Item Group: None Resolution: None Assigned to: None Status: Open Summary: srfi-11 uses gentemp instead of gensym Original Submission: This causes a deprecation warning in code that uses let-value

Re: gensym

2000-09-11 Thread Mikael Djurfeldt
"Dale P. Smith" <[EMAIL PROTECTED]> writes: > gensym is supposed to be called with a symbol, not a string. It still > fails. I apologize for all of these incomplete fixes. I think I've been trying to do too many things simultaneously lately. What I should have don

gensym fixes

2000-09-10 Thread Dale P. Smith
There are a few places where gensym is applied to a string (oooh, that almost sounds like I know scheme!) Here is a patch. dsmith@sammy:~/src/guile/guile-core/ice-9$ cvs diff -u cvs server: Diffing . Index: boot-9.scm === RCS file

Re: gensym

2000-09-08 Thread Dale P. Smith
"Dale P. Smith" wrote: > > I don't thing gensym is right yet. ^ think > > There are about a dozen or so places in calling.scm where gensym is used > with a symbol, I thought recent changes required the first argument to > be a string. Trying it ou

[Fwd: gensym]

2000-09-07 Thread Dale P. Smith
"Dale P. Smith" wrote: > > I don't thing gensym is right yet. > > There are about a dozen or so places in calling.scm where gensym is used > with a symbol, I thought recent changes required the first argument to > be a string. Trying it out, I find: > &g