guile-user
[Top][All Lists]
Advanced

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

Re: [ANN] guile-msgpack: MessagePack for GNU Guile (+ help needed)


From: HiPhish
Subject: Re: [ANN] guile-msgpack: MessagePack for GNU Guile (+ help needed)
Date: Thu, 20 Sep 2018 01:32:12 +0200

John Cowan wrote:
> By convention, Scheme procedures whose only side effect is on a port
> don't use the ! in their names: we write `read`, `write`, `display`, not
> `read!`, `write!`, `display!`.
> 
> I would suggest calling them pack-and-write and read-and-unpack;
> you can leave out the "and-" if you think those are too long.
That's a really good point, I did not think of. In my Racket implementation I 
called the functions without exclamation mark, but that implementation lacks 
pure procedures.

> The Scheme community is small enough that doing a little bit to make
> libraries
> more portable is worthwhile.  I'd use R6RS `library` instead of
> Guile-specific
> `define-module`, and maybe put the code proper into a separate file from the
> module furniture.  (To use `include` or any other Guile-specific procedure
> in an R6RS library, add `(only (guile) include)` to the imports list.)
> Using
> Guile-specific procedures is not usually a problem, as there are probably
> equivalents in other Schemes.
How popular is r6rs anyway? From what I gathered it was pretty badly received 
and r7rs small was intentionally designed to be less ambitious, while the 
upcoming r7rs will be larger than even Common Lisp.

> Usually there's just using a constructor wrapper that checks the types
> before
> calling the real constructor (`cons` in this case).
OK, that was my first idea, but I thought that there might be perhaps 
something more idiomatic.

> Returning a list of values is idiomatic.  It is actually possible for a
> caller to
> receive multiple values without knowing how many it's going to get, but it's
> probably more trouble than it's worth in this case.
Yes, after writing my original email I found out how to bind an unknown number 
of values, but there doesn't seem to be a way of returning an unknown number 
of values.

> GoFundMe seems like the right thing.
GoFundMe is about fundraising campaigns, I was thinking something along the 
lines of a tip-jar where you can chip in a little if you want.






reply via email to

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