[plt-scheme] Re: From hash-table to generator

From: Jens Axel Søgaard (jensaxel at soegaard.net)
Date: Fri May 11 20:33:12 EDT 2007

Hi Kyle,

> I'm trying to reproduce these results;
> 
> Unless I missed the definition in an earlier post,
> I'm not sure how you're defining:
> 
> hash-table->list
> 
> I can't seem to find it in the Help Desk, so I'm assuming
> it's yours.  Please post the definition, or a reference to
> which library it comes from.

Here it is:

(define (hash-table->list ht)
   (let ([xs '()])
     (hash-table-for-each ht
                          (lambda (x v)
                            (set! xs (cons x xs))))
     xs))

-- 
Jens Axel Søgaard



Posted on the users mailing list.