GNU bug report logs -
#51549
29.0.50; flymake error when filename contain '%'
Previous Next
Reported by: Ola x Nilsson <ola.x.nilsson <at> axis.com>
Date: Mon, 1 Nov 2021 11:53:02 UTC
Severity: normal
Tags: confirmed
Found in version 29.0.50
Fixed in version 28.1
Done: Stefan Kangas <stefan <at> marxist.se>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
On Sat, Nov 6, 2021 at 11:08 AM Stefan Kangas <stefan <at> marxist.se> wrote:
> That's what I thought too, until I looked at the code. Unfortunately,
> the fix we both thought of isn't that trivial as we set
> `warning-type-format' like this:
>
> (warning-type-format
> (format " [%s %s]"
> (or sublog 'flymake)
> (current-buffer)))
Ah I see. Then maybe the problem is how that is used forward.
> And then we run `display-warning', which uses this variable as the first
> argument to format.
>
> Is there a strong need to have this format for flymake warnings?
Absolutely not. This is probably one of the most over-engineered
things I put in Flymake. It's occasionally useful, but not terribly so.
> Emergency [flymake foo%sbar.c]: foo
>
> If not, my best idea for fixing this is to remove the filename from the
> `warning-type-format', and put it in the message instead. That would be
> a backwards-incompatible change, however.
Yes, do what you think is best, and thanks in advance.
It's good to have the buffer name where the warning came from,
but it doesn't have to be in that exact place. Maybe just
escaping the "%" in the return value of `current-buffer`
would work though? Doubling the "%" into "%%", perhaps.
João
This bug report was last modified 3 years and 193 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.