This project is read-only.

pfds 0.3 released

Jul 12, 2014 at 5:43 PM
Edited Jul 12, 2014 at 5:44 PM
After a long hiatus, today sees the release of the 0.3 version of

What is it?

Pfds is a collection of purely functional data structures written in
pure R6RS Scheme. It has been tested on Guile 2.0, Racket 5.3, and
trunk IronScheme[0]. There should be no reason for it not to work on
other R6RS Schemes.

What's changed?

Changes to existing modules

  • (pfds bbtrees)
    The function 'bbtree-ref' now takes an optional third argument.

Bug Fixes

  • (pfds bbtrees)
    A typo in 'l-to-r-pre-order' referring to a non-existant identifier
    has been fixed.

New Modules

Since last release, I have added 3 new modules.
  • (pfds queues naive)
    For those of you need a queue data structure, but are using it in a
    mostly linear manner, this implements the simple two list version of
    queues. It has the same interface as (pfds queues), and so can be
    used only by changing the import expression.
  • (pfds deques naive)
    Similar to the situation with (pfds queues naive). This shares the
    same interface with (pfds deques), and so you be used by only
    changing the import expression.
  • (pfds hamts)
    Hash Array Mapped Tries or "HAMTS" are a functional map type. Unlike
    (pfds bbtrees) this uses a hash function, rather than requiring data
    to be ordered. The documentation is at the top of the file.

New Docs

  • doc/dlists
    A readable explanation of the purpose of dlists.
  • examples/queues.scm
    Uses functional queues to a breadth-first search of a tree.


Since last time, I have split all the tests out into a separate file
for each datastructure. You can find them in the tests subdirectory.

Where can you get it?

Source code is available on github

The future

SRFI 101 was meant to be added to this release, but I held off just in
case I ended up taking another long hiatus. This should be added in

There is a fair amount of overhead under the hood which can be
removed, I will try to improve on this for next release.

Better Documentation is going to be a key thing for next release.
While I am already picky about documenting the API in a reference
style at the top of each file. I would like something which can be
more easily HTML-ised and put on my website, and to increase the
number of examples.

As always, if you have any functional data structures you would like
added, that you just want to tell me about, bug reports, feature
requests, examples or benchmarks you'd like me to do better on, do
email me, or open an issue on github.

  1. Thanks as always to leppie.