[Openmcl-devel] (equal '#:G34159 '#:G34159) -> NIL

Taoufik Dachraoui dachraoui.taoufik at gmail.com
Wed Aug 1 19:22:43 UTC 2012


Ok thanks

I solved the problem by doing using (intern (symbol-name (gensym))) instead
of (gensym)

I did not know that the generated symbols do not belong to any package:

(symbol-package '#:G34159)
> NIL

Is there any reason for this? because usually a symbol is interned in the
current package

Kind regards
Taoufik


On Wed, Aug 1, 2012 at 9:07 PM, Ron Garret <ron at flownet.com> wrote:

> You should read this:
>
> http://www.flownet.com/ron/packages.pdf
>
> Particularly section 2.
>
> rg
>
> On Aug 1, 2012, at 12:03 PM, Taoufik Dachraoui wrote:
>
> > Hi
> >
> > I am having a problem with the following:
> >
> > ? (equal '#:G34159 '#:G34159)
> > NIL
> >
> >
> > In the program I use gensym to generate new symbols and in another
> function
> > I compare the symbols for equality
> >
> > How do I fix this? I do not understand how come this 2 generated symbols
> are not equal,
> > is this special rule for generated symbols?
> >
> > Kind regards
> > Taoufik
> >
> > _______________________________________________
> > Openmcl-devel mailing list
> > Openmcl-devel at clozure.com
> > http://clozure.com/mailman/listinfo/openmcl-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.clozure.com/pipermail/openmcl-devel/attachments/20120801/60d34474/attachment.html>


More information about the Openmcl-devel mailing list