[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#29489: Obsolete gnus-remove-if and gnus-remove-if-not

From: Noam Postavsky
Subject: bug#29489: Obsolete gnus-remove-if and gnus-remove-if-not
Date: Tue, 28 Nov 2017 19:40:47 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.90 (gnu/linux)

Eric Abrahamsen <address@hidden> writes:

>> Although the docstring claims "hash table", while the code says...
>>> -    (if hash-table-p
>>> -   (mapatoms (lambda (symbol)
>>> -               (unless (funcall predicate symbol)
>>> -                 (push symbol out)))
>>> -             sequence)
>> obarray?
> Shhh, that's my next patch to Gnus! Turning its "hash tables" into
> actual hash tables. The obarrays are an impressive and horrible hack.
> For this version of the patch, `seq-filter' works on vectors. In the
> next patch, it's replaced by seq-filter->map-keys.

Hmm, seq-filter works on vectors, but it's not reliable for obarrays:

    (let ((list nil)
          (ob (make-vector 3 0)))
      (intern "foo" ob)
      (intern "bar" ob)
      (intern "xxx" ob)
      (seq-filter (lambda (_) t) ob)) ;=> (xxx 0 0)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]