From: Spencer Baugh <sbaugh@janestreet.com>
To: Arash Esbati <arash@gnu.org>
Cc: Vangelis Evangelou <evangelou@gmail.com>, 70816@debbugs.gnu.org
Subject: bug#70816: 29.2; Flymake fails in latex-mode when the buffer is narrowed
Date: Sat, 18 May 2024 10:58:05 -0400 [thread overview]
Message-ID: <iery1879ngi.fsf@janestreet.com> (raw)
In-Reply-To: <ier1q5zb2bs.fsf@janestreet.com> (Spencer Baugh's message of "Sat, 18 May 2024 10:51:35 -0400")
Spencer Baugh <sbaugh@janestreet.com> writes:
> Can you test with the following patch, please?
Context:
It looks like the latex-mode flymake diagnostic function, tex-chktex,
widens before sending the buffer contents to the external linter
process. So the line numbers of errors are reported relative to the
widened buffer, not the narrowed buffer. A number of different checkers
in Emacs seem to do the same thing.
The bug is that these checkers call flymake-diag-region to translate the
line numbers into buffer positions. But flymake-diag-region does not
widen the buffer when doing this translation, so it fails.
I expect you have some flymake logs of the form "Invalid region line=%s
col=%s". when triggering this bug.
Probably the right fix in flymake is to make flymake-diag-region widen,
as in the patch I posted, but that's a bit of a behavior change... will
think about it, but it's probably fine.
next prev parent reply other threads:[~2024-05-18 14:58 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-07 7:56 bug#70816: 29.2; Flymake fails in latex-mode when the buffer is narrowed Vangelis Evangelou
2024-05-07 15:19 ` Arash Esbati
2024-05-18 8:41 ` Eli Zaretskii
2024-05-18 14:51 ` Spencer Baugh
2024-05-18 14:58 ` Spencer Baugh [this message]
2024-05-18 17:11 ` Vangelis Evangelou
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=iery1879ngi.fsf@janestreet.com \
--to=sbaugh@janestreet.com \
--cc=70816@debbugs.gnu.org \
--cc=arash@gnu.org \
--cc=evangelou@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.