Open issues for SRFI 113 John Cowan (04 Dec 2013 04:37 UTC)
Re: Open issues for SRFI 113 Kevin Wortman (08 Dec 2013 04:35 UTC)
Re: Open issues for SRFI 113 John Cowan (08 Dec 2013 18:05 UTC)
Re: Open issues for SRFI 113 John Cowan (08 Dec 2013 18:15 UTC)
Re: Open issues for SRFI 113 Kevin Wortman (09 Dec 2013 00:43 UTC)
Re: Open issues for SRFI 113 John Cowan (09 Dec 2013 08:04 UTC)
Re: Open issues for SRFI 113 Alex Shinn (09 Dec 2013 08:16 UTC)
Re: Open issues for SRFI 113 John Cowan (09 Dec 2013 15:59 UTC)
Re: Open issues for SRFI 113 Alex Shinn (09 Dec 2013 00:39 UTC)
Re: Open issues for SRFI 113 John Cowan (09 Dec 2013 17:13 UTC)
Re: Open issues for SRFI 113 Alex Shinn (10 Dec 2013 01:18 UTC)
Re: Open issues for SRFI 113 John Cowan (10 Dec 2013 21:35 UTC)
Re: Open issues for SRFI 113 Alex Shinn (11 Dec 2013 00:55 UTC)
Re: Open issues for SRFI 113 John Cowan (16 Dec 2013 07:12 UTC)

Re: Open issues for SRFI 113 Kevin Wortman 09 Dec 2013 00:43 UTC

On 12/08/2013 10:05 AM, John Cowan wrote:
>> [13] In my use cases the time and effort that it takes programmers to find
>> and import multiple fine-grained libraries is far costlier than the time
>> it might take a Scheme environment to load a single coarse one, so I say
>> stick with one library.
>
> It's not so much time-to-load as namespace pollution.  The library as
> currently specified introduces 238 identifiers.  Admittedly they are
> named according to a fairly small number of patterns, which hopefully
> will make collisions unlikely.  I'll leave things as they are.

Yeah I think collisions with these names are unlikely, and if they were
to occur, the import syntax has clean ways of handling it.

>> [14] This can be deceptively complex with mutable structures, since all the
>> interactions between mutative operations and pre-existing cursors need
>> to be defined precisely.
>
> Or just say, as Java does and as I do in HashTablesCowan, that the effect
> of mutating a hash table with live cursors is undefined.

That's OK, although it makes some intuitive algorithms impossible to
implement. For example a straightforward way of computing the set
difference (A - B) destructively is

for each element x in set A:
  if x is in set B:
    delete x from A

If the "delete x from A" operation invalidates the "for each element x"
cursor then you're out of luck.

Then again, insisting that live cursors stay valid is a heavy
implementation burden that adds a lot of complexity and effectively
prohibits some data structures.

IMO the better part of valor is to try to get away with not having
cursors into mutable data structures. Almost all use cases can already
be handled by the "Mapping and folding" procedures.

Kevin Wortman