From: Robert Pluim <rpluim@gmail.com>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: 58278@debbugs.gnu.org, Jonas Bernoulli <jonas@bernoul.li>
Subject: bug#58278: Add new function seq-keep
Date: Tue, 04 Oct 2022 13:21:06 +0200 [thread overview]
Message-ID: <878rlval7h.fsf@gmail.com> (raw)
In-Reply-To: <87bkqr3kup.fsf@gnus.org> (Lars Ingebrigtsen's message of "Tue, 04 Oct 2022 13:10:38 +0200")
>>>>> On Tue, 04 Oct 2022 13:10:38 +0200, Lars Ingebrigtsen <larsi@gnus.org> said:
Lars> Robert Pluim <rpluim@gmail.com> writes:
>> Thatʼs why I said "apart from the syntactic sugar" 😀
Lars> Having to rewrite
Lars> (seq-keep #'cl-digit-char-p '(?6 ?a))
Lars> => (6)
Lars> to
Lars> (cl-mapcan (lambda (c)
Lars> (let ((res (cl-digit-char-p c)))
Lars> (and res (list res))))
Lars> '(?6 ?a))
Lars> => (6)
Lars> is more than "syntactic sugar" in my book. Nobody would want to write
Lars> code like the latter.
I never meant that. I meant defining `seq-keep' in terms of `'cl-mapcan',
with the appropriate converting elements to lists done for you (or
even using `mapcan' if youʼre willing to give up the &rest behaviour
of `cl-mapcan')
Robert
--
next prev parent reply other threads:[~2022-10-04 11:21 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-03 21:30 bug#58278: Add new function seq-keep Jonas Bernoulli
2022-10-03 23:47 ` Lars Ingebrigtsen
2022-10-04 10:05 ` Robert Pluim
2022-10-04 10:13 ` Lars Ingebrigtsen
2022-10-04 10:27 ` Robert Pluim
2022-10-04 10:42 ` Lars Ingebrigtsen
2022-10-04 10:50 ` Robert Pluim
2022-10-04 11:10 ` Lars Ingebrigtsen
2022-10-04 11:21 ` Robert Pluim [this message]
2022-10-04 11:23 ` Lars Ingebrigtsen
2022-10-04 11:37 ` Robert Pluim
2022-10-04 12:50 ` Jonas Bernoulli
2022-10-04 13:47 ` Lars Ingebrigtsen
2022-10-04 13:56 ` Lars Ingebrigtsen
2022-10-04 13:59 ` Lars Ingebrigtsen
2022-10-04 19:46 ` Lars Ingebrigtsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=878rlval7h.fsf@gmail.com \
--to=rpluim@gmail.com \
--cc=58278@debbugs.gnu.org \
--cc=jonas@bernoul.li \
--cc=larsi@gnus.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.