From: "Clément Pit-Claudel" <clement.pitclaudel@live.com>
To: Noam Postavsky <npostavs@gmail.com>
Cc: Michael Heerdegen <michael_heerdegen@web.de>, 31715@debbugs.gnu.org
Subject: bug#31715: cl-incf and cl-decf error out when passed a nil-valued variable as 'offset'
Date: Tue, 5 Jun 2018 19:36:41 -0400 [thread overview]
Message-ID: <b8fb26bb-f184-ba23-3f08-80ad78dfd009@live.com> (raw)
In-Reply-To: <87h8mg7r2c.fsf@gmail.com>
[-- Attachment #1.1: Type: text/plain, Size: 1114 bytes --]
On 2018-06-05 19:26, Noam Postavsky wrote:
> Clément Pit-Claudel <clement.pitclaudel@live.com> writes:
>
>> I'm not sure what to make of the result with SBCL and CLisp, since
>> (incf x nil) also fails in both of them (whereas it works for us,
>> since we can't distinguish nil and unspecified).
>
> Oh, huh, I didn't think to check that case. Maybe we should just change
> cl-incf to disintguish between nil and unspecified then.
Hmm, neat trick! Wouldn't that be backwards-incompatible, though?
Plus, it's not common for ELisp functions to distinguish between unspecified and nil, and changing cl-incf that way would make it less convenient to wrap in other macros. If it doesn't had runtime costs, I'd be in favor of going the other route, and making sure that (cl-incf x y) adds 1 even when y is bound to nil.
>>> I don't think those are great examples of macros to emulate.
>>
>> Agreed, I was just collecting other examples, both in support and against my point.
>
> Yeah, I just meant we can't really use those examples either to support
> or argue against your point.
OK :)
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
next prev parent reply other threads:[~2018-06-05 23:36 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-04 20:06 bug#31715: cl-incf and cl-decf error out when passed a nil-valued variable as 'offset' Clément Pit-Claudel
2018-06-04 22:58 ` Noam Postavsky
2018-06-04 23:43 ` Michael Heerdegen
2018-06-05 0:12 ` Noam Postavsky
2018-06-05 0:40 ` Michael Heerdegen
2022-04-21 13:11 ` Lars Ingebrigtsen
2018-06-05 15:19 ` Clément Pit-Claudel
2018-06-05 22:53 ` Noam Postavsky
2018-06-05 23:01 ` Clément Pit-Claudel
2018-06-05 23:26 ` Noam Postavsky
2018-06-05 23:36 ` Clément Pit-Claudel [this message]
2018-06-06 0:32 ` Michael Heerdegen
2018-06-06 0:37 ` Noam Postavsky
2018-06-05 15:03 ` Clément Pit-Claudel
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=b8fb26bb-f184-ba23-3f08-80ad78dfd009@live.com \
--to=clement.pitclaudel@live.com \
--cc=31715@debbugs.gnu.org \
--cc=michael_heerdegen@web.de \
--cc=npostavs@gmail.com \
/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.