Taylan Ulrich Bayırlı/Kammer scripsit:
> Might it be more useful to drop support for list-ref/list-set!, and
> support alists instead?
I would say no. Destructive changes to lists are rare, and destructive
changes to alists are even rarer. People use alists when they want to
bind new values to keys that can easily be dropped later, making the
old values visible again.
Keep lists for compatibility, and forget alists.
> Back to the first idea then: how common is list-ref/list-set! in modern
> Scheme code that uses vectors and records well? How common are alists
> in modern Scheme code that uses hashtables well?
Even though alists are O(n), they may have smaller constant overheads
than hashtables, plus the advantage of easy reset as noted above.
--
John Cowan http://www.ccil.org/~cowan xxxxxx@ccil.org
If I have not seen as far as other giants, it’s because I have been
standing on my head. --Trond Engen