From 68e7250a9facbe7b82cff17af3bf2a831e481f3c Mon Sep 17 00:00:00 2001 From: Alex Wang Date: Tue, 25 Oct 2016 13:30:42 -0400 Subject: Features: Fix cxx_right_angle_brackets compiler feature test The clang-format pass in commit v3.6.0-rc1~54^2~1 (Revise C++ coding style using clang-format, 2016-05-16) changed the template right angle brackets from `>>` to `> >`, which defeats the purpose of this test. Change it back and exclude this content from formatting. --- Tests/CompileFeatures/cxx_right_angle_brackets.cpp | 4 +++- Utilities/Scripts/clang-format.bash | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Tests/CompileFeatures/cxx_right_angle_brackets.cpp b/Tests/CompileFeatures/cxx_right_angle_brackets.cpp index 8f1b0ee..4d494b5 100644 --- a/Tests/CompileFeatures/cxx_right_angle_brackets.cpp +++ b/Tests/CompileFeatures/cxx_right_angle_brackets.cpp @@ -7,6 +7,8 @@ struct A void someFunc() { - A > object; + /* clang-format off */ + A> object; + /* clang-format on */ (void)object; } diff --git a/Utilities/Scripts/clang-format.bash b/Utilities/Scripts/clang-format.bash index a7080fc..ad3b3a1 100755 --- a/Utilities/Scripts/clang-format.bash +++ b/Utilities/Scripts/clang-format.bash @@ -130,6 +130,7 @@ $git_ls -z -- '*.c' '*.cc' '*.cpp' '*.cxx' '*.h' '*.hh' '*.hpp' '*.hxx' | # Exclude manually-formatted sources (e.g. with long lines). egrep -z -v '^Tests/PositionIndependentTargets/pic_test.h' | + egrep -z -v '^Tests/CompileFeatures/cxx_right_angle_brackets.cpp' | # Exclude sources with encoding not suported by clang-format. egrep -z -v '^Tests/RunCMake/CommandLine/cmake_depends/test_UTF-16LE.h' | -- cgit v0.12