Email list hosting service & mailing list manager

port-or-generator argument in reference implementation Shiro Kawai (04 Aug 2020 21:39 UTC)
Re: port-or-generator argument in reference implementation Amirouche Boubekki (05 Aug 2020 06:35 UTC)
Re: port-or-generator argument in reference implementation Arthur A. Gleckler (05 Aug 2020 06:37 UTC)
Re: port-or-generator argument in reference implementation Amirouche Boubekki (07 Aug 2020 03:08 UTC)
Re: port-or-generator argument in reference implementation Amirouche Boubekki (07 Aug 2020 16:27 UTC)
Re: port-or-generator argument in reference implementation Arthur A. Gleckler (07 Aug 2020 18:19 UTC)

Re: port-or-generator argument in reference implementation Amirouche Boubekki 05 Aug 2020 06:34 UTC

Hello Shiro :)

Le mar. 4 août 2020 à 23:39, Shiro Kawai <xxxxxx@gmail.com> a écrit :
>
> json-fold is supposed to take a port or a char generator, but in the reference
> implementation it passes the argument directly to json-generator, which only
> accepts a port.

json-generator passes its arguments to json-tokens which accepts a
port or generator. Indeed there is a mistake in the specification
json-generator should mention port-or-generator as argument.

> By the way, the srfi text of json-fold says : "The behavior of json-fold is only
> specified when PORT-OR-GENERATOR follows the json-generator protocol."
> What does "json-generator protocol" mean?

The json-generator protocol at
https://srfi.schemers.org/srfi-180/srfi-180.html#json-generator-port