Re: [racket-users] Re: srfi-171 transducers for racket

2019-12-10 Thread Linus Björnstam
For racket it does not work out of the box, but for scheme srfi69 allows for arbitrary equality predicates and specialized hash functions. I believe r6rs hashtables has a string-CI-hash, but I can be wrong. For the racket port I removed that functionality, since I couldn't do it easily using th

Re: [racket-users] Re: srfi-171 transducers for racket

2019-12-10 Thread Jack Firth
> > The "tdelete-duplicates" uses a hash-table to store already seen elements: > if the element is in the hash table, just filter it out. If it is not, we > do: (hash-set! already-seen element #t). That should be constant timeish. > I understand how that works for the usual eq? / eqv? / equal

Re: [racket-users] Re: srfi-171 transducers for racket

2019-12-10 Thread Linus Björnstam
Hi Jack! The "tdelete-duplicates" uses a hash-table to store already seen elements: if the element is in the hash table, just filter it out. If it is not, we do: (hash-set! already-seen element #t). That should be constant timeish. This means that you cannot (and should not) use the same reduc