[haiku-development] Re: Checker bot for Gerrit

  • From: "Adrien Destugues" <pulkomandy@xxxxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Wed, 23 Jun 2021 15:29:38 +0000

As Niels commented, this is not something that clang-format should handle. 
The second option
suggested by Adrien is the way to go.

I don't agree. The solution that Saloni has come up with, which detects 
simple keywords
like "BLayoutBuilder" and "AddGroup" without doing in-depth syntax analysis, 
is giving promising
results. And the implementation is not that complex.

I guess the question is on whether we want to integrate our changes back into 
clang-format, or
whether we want to maintain a fork with this kind of specific customizations. 
I do not have a
preference on that.

That choice is rather on the side of llvm developers. Indeed I doubt they would 
accept something
so specific to Haiku in upstream. So if we do this, we have to maintain the 
patch. I think it is
an acceptable cost compared to the improved usefulness of the tool.

-- 
Adrien.


Other related posts: