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

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

bug#24623: 25.1; Flymake turns off if check command fails without report


From: Dave Abrahams
Subject: bug#24623: 25.1; Flymake turns off if check command fails without reporting errors in the file being edited
Date: Sat, 4 Nov 2017 10:41:20 -0700


> On Nov 3, 2017, at 4:51 AM, João Távora <joaotavora@gmail.com> wrote:
> 
> Dave Abrahams <dave@boostpro.com> writes:
> 
>> In these lines from flymake-post-syntax-check:
>> 
>>      (if (and (equal 0 err-count) (equal 0 warn-count))
>>          (if (equal 0 exit-status)
>>              (flymake-report-status "" "") ; PASSED
>>            (if (not flymake-check-was-interrupted)
>>                (flymake-report-fatal-status "CFGERR"
>>                                             (format "Configuration error has 
>> occurred while running %s" command))
>>              (flymake-report-status nil ""))) ; "STOPPED"
>>        (flymake-report-status (format "%d/%d" err-count warn-count) "")))))
>> 
>> err-count and warn-count are the count of errors detected *in the file
>> being edited*.  My syntax check command must consider a whole batch of
>> files at once, and sometimes those other files have errors in them.
>> That should not disable syntax checking in the current file, but flymake
>> has this behavior unconditionally, and there's no way to turn it off.
> 
> [Eli, I’m CC’ing you since I think this bug can be marked "wontfix" or
> equivalent]
> 
> Hello Dave and sorry for the extremely late reply to this bug.
> 
> This is easy to reproduce with GCC as a checker tool when checking a .h
> file with no errors but included by a .c file with some errors.
> 
> I just wanted to note, if you haven’t noticed already, that Flymake has
> been redesigned in the upcoming Emacs 26 and the functionality you refer
> to is now considered obsolete.
> 
> Nevertheless, it is still supported and lives in a so called "legacy
> backend". Your particular problem also popped up for me testing. My
> solution would be to invoke your syntax checker tool in a way that the
> invocation univocally returns 0, like having this in a Makefile:
> 
> syntax-check:
>       mytool $(CHK_SOURCES) || true
> 
> But there are new much better ways to configure Flymake with your syntax
> checker. They are described in the Flymake Info manual, which also
> broadly describes the redesign effort). You can read this manual with
> M-x info in the upcoming Emacs version (or one of the already available
> pretests thereof).
> 
> Given the workaround, I don’t there’s much reason to fix this.

Hadn't noticed, thanks.  I'll have to upgrade my emacs I guess.  Thanks for the 
update.




reply via email to

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