[Top][All Lists]

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

Re: [PATCH] Flymake support for C/C++

From: Stefan Monnier
Subject: Re: [PATCH] Flymake support for C/C++
Date: Sat, 02 Jun 2018 13:16:20 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

> I've had another look at your proposed cc-flymake.el.  It doesn't use
> any CC Mode interfaces or data structures.  It uses lots of flymake
> interfaces and data structures.  It has nothing to do with CC Mode's
> source files; it is an integral part of flymake, and should be called
> something like flymake-cc.el and maintained together with the rest of
> flymake.

I agree that it's not specific to CC-mode.

It should also work for several languages not supported by CC-mode,
for example.  Maybe it'd be better to think of it as "flymake support
for GNU tools" (e.g. it relies on the GNU Coding Standard format of
error/warning messages).

But I think that the part of the code which tells flymake to use
this "flymake for GNU tools" code does belong with c-mode.

> Imenu support (in cc-menus.el) isn't really part of CC Mode either, but
> is there by tradition.

That makes it sound like you'd rather remove imenu support from CC-mode.
I think that would be a disservice to (y)our users.
For the same reason I think cc-mode should incorporate something like

    (add-hook 'flymake-diagnostic-functions #'flymake-cc nil t)

in its code.  Just as is the case for Imenu code, you (as maintainer of
CC-mode) don't really have to actively support the code, you just accept
to keep it under your roof as long as it doesn't misbehave.


reply via email to

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