Re: srfi-88 keyword / symbol ambiguity

2008-07-21 Thread Ludovic Courtès
Hi,

"Julian Graham" <[EMAIL PROTECTED]> writes:

> guile> (keyword? 'foo:)
> #t

This is expected, per SRFI-88.

> This is particularly bad because it breaks a lot of code that calls
> `use-modules' with the :prefix or :rename syntax -- from looking at some
> of the core libraries, it seems like it's pretty common to use
> rename-prefixes that end in a colon.  So, for example, the ice-9 debugger
> modules don't work after loading `(srfi srfi-88)'.

Good point.  Alas, that's hardly avoidable, given that the above
behavior is defined by SRFI-88.

One way to avoid it would be to not have a mutable global reader.  This
can be achieved using the `current-reader' fluid and something like
Guile-Reader, which produces immutable `read' procedures:

  http://www.nongnu.org/guile-reader/doc/guile-reader.html#Quick-Start

Thanks,
Ludovic.





Re: srfi-88 keyword / symbol ambiguity

2008-07-21 Thread Neil Jerram
2008/7/20 Julian Graham <[EMAIL PROTECTED]>:
>
> This is particularly bad because it breaks a lot of code that calls
> `use-modules' with the :prefix or :rename syntax -- from looking at some of
> the core libraries, it seems like it's pretty common to use rename-prefixes
> that end in a colon.  So, for example, the ice-9 debugger modules don't work
> after loading `(srfi srfi-88)'.

If it helps you in the short term, please feel free to look at
patching those modules so that they use a prefix that doesn't end with
a colon.  I think that should be compatible in API terms, because the
prefixed names are only used internally within the using module.

> I'm not sure yet what the fix would be -- maybe the reader should avoid
> converting a token into a postfix-style keyword if it's obvious from the
> read state that a symbol is desired (i.e., the quote character is prefixed),
> but that probably doesn't cover all the possibilities.

That sounds very tricky!  As Ludovic said, I think read options need
somehow to be less global - whether via Guile-Reader, or otherwise.

  Neil




Re: What new libraries or functionality does Guile need?

2008-07-21 Thread JonWilson
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

It seems that snd has a significant amount of functionality that might
be generally useful.  Would it be possible for the snd team to spend
some time factoring out these things?  I know that snd-c and the GL
bindings have been mentioned here, but I suspect there are other things
as well?
Regards,
Jon

Kjetil S. Matheussen wrote:
> 
> "Jose A. Ortega Ruiz":
>>> Hi-
>>
>>> If you could ask someone to write a library or package a set of
>>> functionality for Guile that it doesn't currently have, what would it
>>> be? (My personal projects are near completion, and I may have some
>>> Saturdays free.)
>>
>> Bindings for OpenGL/GLU/GLUT would be great.
>>
> 
> Snd should have bindings for those:
> http://snd.sf.net
> 
> 
> 

-BEGIN PGP SIGNATURE-
Version: GnuPG v2.0.9 (GNU/Linux)
Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org

iEYEARECAAYFAkiEsxUACgkQ3y6HU3bfjw5RMACgqBl5OWUDoNv+l1hjIu+l4+/i
ko8AoIQzV1CDFZY5yKah/O5dU9wpJPeh
=rztq
-END PGP SIGNATURE-