From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Thierry Volpiatto <thierry.volpiatto@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: false warnings when compiling with lexical-binding and cl-lib.
Date: Sun, 24 Nov 2013 13:08:35 -0500 [thread overview]
Message-ID: <jwv4n71wudu.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <878uwfulw5.fsf@gmail.com> (Thierry Volpiatto's message of "Sat, 23 Nov 2013 17:24:10 +0100")
>> Also the warning is only at compile time, should we return an error on
>> evaluation ?
I don't see why we should bother with an error.
(let* ((a 1) (a 2)) ...)
is not very useful, but it's not an error. The warning we currently
have is not perfect because it applies to the post-macroexpansion code,
so the user may not immediately understand what's going on, but your
suggested patch has the following downsides:
- it breaks previously working code.
- it does not tell you where (approximate line number) the error is located.
So if we want to improve on the current code, I think rather than
`cl-assert' we should use macroexp--warn-and-return (grep for it to see
sample uses). But the patch won't be as trivial.
Stefan
prev parent reply other threads:[~2013-11-24 18:08 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-21 15:29 false warnings when compiling with lexical-binding and cl-lib Thierry Volpiatto
2013-11-22 1:19 ` Stefan Monnier
2013-11-22 5:33 ` Thierry Volpiatto
2013-11-22 7:48 ` Thierry Volpiatto
2013-11-23 6:13 ` Thierry Volpiatto
2013-11-23 13:51 ` Stefan Monnier
2013-11-23 15:53 ` Thierry Volpiatto
2013-11-23 16:24 ` Thierry Volpiatto
2013-11-24 18:08 ` Stefan Monnier [this message]
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=jwv4n71wudu.fsf-monnier+emacs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=emacs-devel@gnu.org \
--cc=thierry.volpiatto@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.