From: "Miguel V. S. Frasson" <mvsfrasson@gmail.com>
To: "Basil L. Contovounesios" <contovob@tcd.ie>
Cc: Michael Heerdegen <michael_heerdegen@web.de>,
Nicolas Petton <nicolas@petton.fr>,
Stefan Monnier <monnier@iro.umontreal.ca>,
34852@debbugs.gnu.org
Subject: bug#34852: 26.1; seq-intersection ignores nil as element
Date: Fri, 15 Mar 2019 13:08:50 -0300 [thread overview]
Message-ID: <CAARdmY0ARVv+fc_BKHvbH4mxph=NXvQnN-cNyxjU5XShLrbNBw@mail.gmail.com> (raw)
In-Reply-To: <875zskrv18.fsf@tcd.ie>
[-- Attachment #1: Type: text/plain, Size: 1384 bytes --]
Hi
I was convinced by the discussions here that changing seq-contains is a bad
idea.
I had the false premise that ELT=nil makes seq-contains return nil.
If I could make a suggestion, it would be include an &optional NOT-FOUND to
be the value returned in case of not finding any element matching TESTFN.
Cheers
Miguel
Em sex, 15 de mar de 2019 12:56, Basil L. Contovounesios <contovob@tcd.ie>
escreveu:
> Michael Heerdegen <michael_heerdegen@web.de> writes:
>
> > "Miguel V. S. Frasson" <mvsfrasson@gmail.com> writes:
> >
> >> In any case, of another implementation for seq-intersection or not, I
> >> think that the solution from Stefan should be implemented anyway
> >> because
> >>
> >> * it makes seq-contains provide a useful return value when ELT=nil, so
> >> it is a good exception; If ELT=nil, seq-contains currently returns nil
> >> anyway;
> >>
> >> * it makes seq-contains become a real predicate function, making it
> >> more useful;
> >>
> >> * since seq-contains has been used as predicate before, it is
> >> unpredictable which code uses it out of official repositories, so this
> >> fix potentially fixes other code.
> >
> > BTW, another (alternative) alternative would be to make it return
> > (list ELT). That would be a bit less backward-compatible, but a
> > bit more consistent.
>
> +1, either this or returning a boolean is fine with me.
>
> --
> Basil
>
[-- Attachment #2: Type: text/html, Size: 2329 bytes --]
next prev parent reply other threads:[~2019-03-15 16:08 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-14 2:16 bug#34852: 26.1; seq-intersection ignores nil as element Miguel V. S. Frasson
2019-03-14 12:07 ` Michael Heerdegen
2019-03-14 13:09 ` Nicolas Petton
2019-03-14 12:22 ` Basil L. Contovounesios
2019-03-14 12:52 ` Miguel V. S. Frasson
2019-03-14 16:16 ` Basil L. Contovounesios
2019-03-14 13:09 ` Michael Heerdegen
2019-03-14 13:34 ` Stefan Monnier
2019-03-14 16:19 ` Basil L. Contovounesios
2019-03-14 16:45 ` Michael Heerdegen
2019-03-14 17:14 ` Basil L. Contovounesios
2019-03-14 19:08 ` Miguel V. S. Frasson
2019-03-14 21:43 ` Stefan Monnier
2019-03-14 23:08 ` Miguel V. S. Frasson
2019-03-14 23:14 ` Stefan Monnier
2019-03-14 23:21 ` Miguel V. S. Frasson
2019-03-14 23:42 ` Michael Heerdegen
2019-03-15 2:40 ` Stefan Monnier
2019-03-15 12:26 ` Michael Heerdegen
2019-03-15 14:47 ` Stefan Monnier
2019-03-14 23:45 ` Miguel V. S. Frasson
2019-03-14 23:15 ` Michael Heerdegen
2019-03-15 15:56 ` Basil L. Contovounesios
2019-03-15 16:08 ` Miguel V. S. Frasson [this message]
2019-03-16 20:33 ` Miguel V. S. Frasson
2019-03-16 20:49 ` Basil L. Contovounesios
2019-03-16 21:32 ` Miguel V. S. Frasson
2019-03-15 15:55 ` Basil L. Contovounesios
2019-03-14 16:17 ` Basil L. Contovounesios
2019-03-14 16:35 ` Michael Heerdegen
2019-03-14 17:02 ` Basil L. Contovounesios
2019-03-14 17:23 ` Basil L. Contovounesios
2019-03-14 16:45 ` Nicolas Petton
2019-03-14 17:08 ` Basil L. Contovounesios
2019-03-18 11:55 ` Nicolas Petton
2019-03-18 19:06 ` Michael Heerdegen
2019-03-18 20:14 ` Nicolas Petton
2019-03-20 20:51 ` Nicolas Petton
2019-03-20 22:33 ` Michael Heerdegen
2019-03-21 8:02 ` Nicolas Petton
2019-03-21 17:46 ` Basil L. Contovounesios
2019-03-21 20:01 ` Nicolas Petton
2019-03-21 20:16 ` Nicolas Petton
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='CAARdmY0ARVv+fc_BKHvbH4mxph=NXvQnN-cNyxjU5XShLrbNBw@mail.gmail.com' \
--to=mvsfrasson@gmail.com \
--cc=34852@debbugs.gnu.org \
--cc=contovob@tcd.ie \
--cc=michael_heerdegen@web.de \
--cc=monnier@iro.umontreal.ca \
--cc=nicolas@petton.fr \
/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.