[polly] r174368 - TempScopInfo: clang-format

Tobias Grosser tobias at grosser.es
Tue Feb 5 09:34:58 PST 2013


On 02/05/2013 06:17 PM, Sebastian Pop wrote:
> Tobias Grosser wrote:
>> Author: grosser
>> Date: Tue Feb  5 06:27:23 2013
>> New Revision: 174368
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=174368&view=rev
>> Log:
>> TempScopInfo: clang-format
>
> I like these changes.  Do you mind sharing the clang flags you used, or even
> better, adding a target to our build system to check syntax? (We may want to
> -Werror for the check-syntax target.)
>
> Thanks for all these cleanups!

I like them too ;-)

They have been brought to you by clang-format and we need to thank 
Daniel Jasper and Manual Klimek.

Regarding the practical use of the tools there is some description 
available here:

http://clang.llvm.org/docs/ClangFormat.html

Basically you need to install the clang-format binary, which can then be 
used to format an entire file, a section marked in vim or the sections 
touched by a patch. There is not yet an emacs plugin available, but 
writing one should be easy after having looked at the vim plugin.

Polly itself is not yet fully clang-format clean as there are still some 
open issues in the tool. For now I believe the best we can do is to 
check individual commits if they introduce new formatting errors.
For this I basically commit my change, use the diff-formatting tool to
reformat the areas that have been changed. If this does not yield any
changes, the code is well formatted. Otherwise, we either have a 
clang-format bug that can be reported or we can apply the formatting fixes.

Cheers
Tobi




More information about the llvm-commits mailing list