unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Noam Postavsky <npostavs@users.sourceforge.net>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 21681@debbugs.gnu.org
Subject: bug#21681: [PATCH] Fix formatting of lexical-binding at eof warning
Date: Sat, 31 Oct 2015 18:36:40 -0400	[thread overview]
Message-ID: <CAM-tV-_3EuQFTsPiTopXhzr+fGdHB68fUYVYnM94ms31+LRqcA@mail.gmail.com> (raw)
In-Reply-To: <CAM-tV-8vH=yATR758A+s-TzqsNza6GLQgLTHsv6j5MrFgwJycg@mail.gmail.com>

On Wed, Oct 14, 2015 at 1:47 PM, Noam Postavsky
<npostavs@users.sourceforge.net> wrote:
> On Wed, Oct 14, 2015 at 1:42 PM, Eli Zaretskii <eliz@gnu.org> wrote:
>>> Date: Wed, 14 Oct 2015 12:56:28 -0400
>>> From: Noam Postavsky <npostavs@users.sourceforge.net>
>>> own, but display-warning only prints the 1st symbol of the list so the
>>> warning text itself wouldn't change.
>>
>> I find "files" no more explanatory that "warning".  If we lack
>> infrastructure to display meaningful messages that unequivocally point
>> to the nature of the problem, let's add the missing infrastructure.
>
> How about making display-warning print all TYPE symbols then?

I've been playing a bit more with display-warning, and I think the
part in brackets is not supposed to be part of the warning's
explanation, but rather it tells you how to block it. Like gcc's
"[-Wfoo]". The problem with printing all the symbols is that it would
make the warnings using TYPE lists longer, pushing the actual warning
text to the right, and discourage use of more specific TYPEs.

Another possiblity is still to truncate to a single item, but show a
"..." button to expand it, like `eval-last-sexp' does for long lists.

Another thing I've been experimenting with is including buttons with
an action to resolve the problem in the warning text. It seems to work
pretty well, except that because *Warnings* is in special-mode <tab>
isn't bound to forward-button. It could be nice to have a
warnings-mode which does that. It could also bind e.g. `i' to
something like ignore-warning-at-point (which would customize
warning-suppress-types). But I know Emacs supposed to be in feature
freeze so maybe now is not the time to be adding new modes.





  parent reply	other threads:[~2015-10-31 22:36 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-13 22:51 bug#21681: [PATCH] Fix formatting of lexical-binding at eof warning Noam Postavsky
2015-10-14 16:28 ` Eli Zaretskii
2015-10-14 16:56   ` Noam Postavsky
2015-10-14 17:42     ` Eli Zaretskii
2015-10-14 17:47       ` Noam Postavsky
2015-10-14 17:53         ` Eli Zaretskii
2015-10-14 19:46           ` Eli Zaretskii
2015-10-15  2:30             ` Noam Postavsky
2015-10-31 22:36         ` Noam Postavsky [this message]
2016-01-24 18:43           ` Noam Postavsky
2016-01-24 18:51             ` Eli Zaretskii
2016-01-24 19:34               ` Noam Postavsky
2016-01-25 17:07                 ` Eli Zaretskii
2016-01-31 15:56                   ` Noam Postavsky
2016-02-03 17:49                     ` Eli Zaretskii

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAM-tV-_3EuQFTsPiTopXhzr+fGdHB68fUYVYnM94ms31+LRqcA@mail.gmail.com \
    --to=npostavs@users.sourceforge.net \
    --cc=21681@debbugs.gnu.org \
    --cc=eliz@gnu.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 public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).