all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "João Távora" <joaotavora@gmail.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: Lars Ingebrigtsen <larsi@gnus.org>, 55811@debbugs.gnu.org
Subject: bug#55811: 29.0.50; No flymake diagnostics for no-byte-compile files
Date: Tue, 07 Jun 2022 07:41:41 +0100	[thread overview]
Message-ID: <87k09t561m.fsf@gmail.com> (raw)
In-Reply-To: <jwv5ylepvb6.fsf-monnier+emacs@gnu.org> (Stefan Monnier's message of "Sun, 05 Jun 2022 19:09:17 -0400")

Hi Stefan,

Stefan Monnier <monnier@iro.umontreal.ca> writes:

> That's a slightly different case from mine: the `no-byte-compile` is
> often used either because the user really only ever wants to load the
> `.el` or because the compilation is known to fail (e.g. because it
> requires macros defined in a package that's not marked as a strict
> dependency, very common in tests).

By this you mean that the provider of such macros is not `require`d?
Then I don't understand what Flymake's byte-compilation backend could do
about this either...  As far as I understand it would just red-underline
all the unknown macro-using forms, their bodies wouldn't be checked.  Is
this what you want?  To check the rest of the file regardless?

Of course you know this -- but just to clarify -- the byte-compilation
backend works by launching a Emacs -Q which is asked to byte-compile
only a file containing the current buffer's contents.  During that
byte-compilation nothing more is loaded apart from what is preloaded or
explicitly loaded by the file at compile-time (via require or
eval-when/and-compile stuff).

A related issue is that when there _is_ an explicit require, then the
load-path support is pretty poor: only the current directory is added to
it.  If the `require`'d file lives somewhere else, there's no way to
hint that to the byte-comp backend, with a particular load-path.

Anyway, maybe you could give small example of such a file containing
such a cookie where you think Flymake's "I refuse to lint this" behavior
could be improved.

João







  parent reply	other threads:[~2022-06-07  6:41 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-05 20:22 bug#55811: 29.0.50; No flymake diagnostics for no-byte-compile files Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-05 20:33 ` Lars Ingebrigtsen
2022-06-05 23:09   ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-06 12:40     ` Lars Ingebrigtsen
2022-06-07  6:41     ` João Távora [this message]
2022-06-07 11:47       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-07 11:54         ` Lars Ingebrigtsen
2022-06-07 12:13           ` João Távora
2022-06-07 13:46             ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-07 12:34           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-07 12:42             ` Lars Ingebrigtsen
2022-06-07 13:49               ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-06-07 12:02         ` João Távora

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=87k09t561m.fsf@gmail.com \
    --to=joaotavora@gmail.com \
    --cc=55811@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    --cc=monnier@iro.umontreal.ca \
    /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.