guile-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: cannot compile: srfi-10 define-reader-ctor 'hash '#,(


From: Jan Nieuwenhuizen
Subject: Re: cannot compile: srfi-10 define-reader-ctor 'hash '#,(
Date: Wed, 13 Aug 2014 21:59:32 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux)

Ludovic Courtès writes:

> The problem is that SRFI-10 itself does not specify an external
> representation for hash tables, nor does Guile.  Thus this patch cannot
> be applied.

Yes, I understand that...Still, "wouldn't it be nice" if Scheme/Guile
had something that javascript has, in JSON hash tables are "simply"

   {"key0": value, "key1": value}

and although that's in some way much uncooler and restricted and set-in
stone wrt Scheme readers and SRFI-10...you *are* able to stream and
communicate objects over ascii/utf-8, unlike #,(hash ...

Here we are with a unimaginable cool srfi-10 reader extension, but we
cannot really use it to communicate.

> Another problem is that (ice-9 pretty-print) is not extensible.  It
> would be ideal if one could extend it with new pretty-printing methods.
> Would you like to work on such a generic mechanism?

Yes, for now I agree that seems to be the only and most pragmatic
solution.  I would like to look into that.

> Ideally ‘pretty-print’ would have an extra keyword parameter that would
> allow users to pass a list of predicate/printer pairs.  There could be a
> ‘pretty-printer-method’ procedure (rather than ‘cons’) to construct such
> a pair.

That sounds nice.  I will look into it.  Thanks for the suggestions!

Greetings, Jan

-- 
Jan Nieuwenhuizen <address@hidden> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | Avatar®  http://AvatarAcademy.nl  



reply via email to

[Prev in Thread] Current Thread [Next in Thread]