bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#57884: [PATCH] Flymake backend using the shellcheck program


From: Augusto Stoffel
Subject: bug#57884: [PATCH] Flymake backend using the shellcheck program
Date: Mon, 19 Sep 2022 09:33:54 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

On Sun, 18 Sep 2022 at 21:18, Philip Kaludercic wrote:

> Philip Kaludercic <philipk@posteo.net> writes:
>
>>> Anyway, I rewrote the backend to use the JSON output of shellcheck,
>>> which has the advantage that it provides the end position of each
>>> diagnostic, so Flymake doesn't have to guess it (which is by nature
>>> sometimes inaccurate).  Let me know what you think.
>>
>> LGTM, but I haven't tested it yet.
>
> I just tried it out and it behaves the way you advertised it.

Okay, so for whoever feels inclined to merge this, please consider the
patch in my message of Sun, 18 Sep 2022 21:38:17 +0200.

> BTW, this diff describes the changes required if you were to pull out
> the sentinel definition into a named function:
> [...]
> I still don't think it looks that bad, but I don't insist on it.

I still don't understand the motivation for this.  Closures are the
perfect tool for this job, and you seem to be just reinventing them. If
I wanted to create a helper function (which I don't really find
necessary from the code organization perspective in this case, although
it might well be in the proselint case), then I'd pass this as :sentinel
argument to make-process:

  (lambda (proc _event) (helper-function proc source report-fn))





reply via email to

[Prev in Thread] Current Thread [Next in Thread]