diff options
author | Kitware Robot <kwrobot@kitware.com> | 2016-05-16 14:34:04 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2016-05-16 20:05:19 (GMT) |
commit | d9fd2f5402eeaa345691313658e02b51038f570b (patch) | |
tree | dca71b9a7e267f4c6300da3eb770415381726785 /Tests/Dependency | |
parent | 82df6deaafb36cbbfd450202bb20b320f637751a (diff) | |
download | CMake-d9fd2f5402eeaa345691313658e02b51038f570b.zip CMake-d9fd2f5402eeaa345691313658e02b51038f570b.tar.gz CMake-d9fd2f5402eeaa345691313658e02b51038f570b.tar.bz2 |
Revise C++ coding style using clang-format
Run the `Utilities/Scripts/clang-format.bash` script to update
all our C++ code to a new style defined by `.clang-format`.
Use `clang-format` version 3.8.
* If you reached this commit for a line in `git blame`, re-run the blame
operation starting at the parent of this commit to see older history
for the content.
* See the parent commit for instructions to rebase a change across this
style transition commit.
Diffstat (limited to 'Tests/Dependency')
34 files changed, 91 insertions, 39 deletions
diff --git a/Tests/Dependency/Case1/a.c b/Tests/Dependency/Case1/a.c index d702db1..262f523 100644 --- a/Tests/Dependency/Case1/a.c +++ b/Tests/Dependency/Case1/a.c @@ -1,5 +1,4 @@ int a() { - return 5; + return 5; } - diff --git a/Tests/Dependency/Case1/b.c b/Tests/Dependency/Case1/b.c index 6bdfafa..deda685 100644 --- a/Tests/Dependency/Case1/b.c +++ b/Tests/Dependency/Case1/b.c @@ -2,5 +2,5 @@ extern int a(); int b() { - return a()+17; + return a() + 17; } diff --git a/Tests/Dependency/Case1/b2.c b/Tests/Dependency/Case1/b2.c index f37e1bb..f341da7 100644 --- a/Tests/Dependency/Case1/b2.c +++ b/Tests/Dependency/Case1/b2.c @@ -1,4 +1,4 @@ int b2() { - return 3; + return 3; } diff --git a/Tests/Dependency/Case1/c.c b/Tests/Dependency/Case1/c.c index c180a59..a3ec162 100644 --- a/Tests/Dependency/Case1/c.c +++ b/Tests/Dependency/Case1/c.c @@ -2,5 +2,5 @@ extern int b(); int c() { - return b()+42; + return b() + 42; } diff --git a/Tests/Dependency/Case1/c2.c b/Tests/Dependency/Case1/c2.c index 4cf4426..317bb0f 100644 --- a/Tests/Dependency/Case1/c2.c +++ b/Tests/Dependency/Case1/c2.c @@ -2,5 +2,5 @@ extern int b2(); int c2() { - return b2()+1; + return b2() + 1; } diff --git a/Tests/Dependency/Case1/d.c b/Tests/Dependency/Case1/d.c index ea5457d..f67aef7 100644 --- a/Tests/Dependency/Case1/d.c +++ b/Tests/Dependency/Case1/d.c @@ -2,6 +2,5 @@ extern int c2(); int d() { - return c2()+2; + return c2() + 2; } - diff --git a/Tests/Dependency/Case1/main.c b/Tests/Dependency/Case1/main.c index 1e5f6d4..07191cc 100644 --- a/Tests/Dependency/Case1/main.c +++ b/Tests/Dependency/Case1/main.c @@ -4,7 +4,7 @@ extern int d(); int main() { - c(); - b(); - d(); + c(); + b(); + d(); } diff --git a/Tests/Dependency/Case2/bar1.c b/Tests/Dependency/Case2/bar1.c index 6108fba..6da9077 100644 --- a/Tests/Dependency/Case2/bar1.c +++ b/Tests/Dependency/Case2/bar1.c @@ -1,4 +1,10 @@ extern int foo1(); extern int bar2(void); -int bar1(void) { return bar2(); } -int bar1_from_bar3(void) { return foo1(); } +int bar1(void) +{ + return bar2(); +} +int bar1_from_bar3(void) +{ + return foo1(); +} diff --git a/Tests/Dependency/Case2/bar2.c b/Tests/Dependency/Case2/bar2.c index b9a2360..00ed483 100644 --- a/Tests/Dependency/Case2/bar2.c +++ b/Tests/Dependency/Case2/bar2.c @@ -1,2 +1,5 @@ extern int bar3(void); -int bar2(void) { return bar3(); } +int bar2(void) +{ + return bar3(); +} diff --git a/Tests/Dependency/Case2/bar3.c b/Tests/Dependency/Case2/bar3.c index 73e8556..a950899 100644 --- a/Tests/Dependency/Case2/bar3.c +++ b/Tests/Dependency/Case2/bar3.c @@ -1,2 +1,5 @@ extern int bar1_from_bar3(void); -int bar3(void) { return bar1_from_bar3(); } +int bar3(void) +{ + return bar1_from_bar3(); +} diff --git a/Tests/Dependency/Case2/foo1.c b/Tests/Dependency/Case2/foo1.c index 5f1f8ac..d476f2c 100644 --- a/Tests/Dependency/Case2/foo1.c +++ b/Tests/Dependency/Case2/foo1.c @@ -1,2 +1,5 @@ extern int foo2(void); -int foo1(void) { return foo2(); } +int foo1(void) +{ + return foo2(); +} diff --git a/Tests/Dependency/Case2/foo1b.c b/Tests/Dependency/Case2/foo1b.c index e2b6dc3..e437014 100644 --- a/Tests/Dependency/Case2/foo1b.c +++ b/Tests/Dependency/Case2/foo1b.c @@ -1,2 +1,5 @@ extern int foo2b(void); -int foo1b(void) { return foo2b(); } +int foo1b(void) +{ + return foo2b(); +} diff --git a/Tests/Dependency/Case2/foo1c.c b/Tests/Dependency/Case2/foo1c.c index 1dcca58..af03dec 100644 --- a/Tests/Dependency/Case2/foo1c.c +++ b/Tests/Dependency/Case2/foo1c.c @@ -1,2 +1,5 @@ extern int foo2c(void); -int foo1c(void) { return foo2c(); } +int foo1c(void) +{ + return foo2c(); +} diff --git a/Tests/Dependency/Case2/foo2.c b/Tests/Dependency/Case2/foo2.c index 6019236..587c77a 100644 --- a/Tests/Dependency/Case2/foo2.c +++ b/Tests/Dependency/Case2/foo2.c @@ -1,2 +1,5 @@ extern int foo3(void); -int foo2(void) { return foo3(); } +int foo2(void) +{ + return foo3(); +} diff --git a/Tests/Dependency/Case2/foo2b.c b/Tests/Dependency/Case2/foo2b.c index 34d6944..6959e63 100644 --- a/Tests/Dependency/Case2/foo2b.c +++ b/Tests/Dependency/Case2/foo2b.c @@ -1,2 +1,5 @@ extern int foo3b(void); -int foo2b(void) { return foo3b(); } +int foo2b(void) +{ + return foo3b(); +} diff --git a/Tests/Dependency/Case2/foo2c.c b/Tests/Dependency/Case2/foo2c.c index dbc54de..aedb61c 100644 --- a/Tests/Dependency/Case2/foo2c.c +++ b/Tests/Dependency/Case2/foo2c.c @@ -1,2 +1,5 @@ extern int foo3c(void); -int foo2c(void) { return foo3c(); } +int foo2c(void) +{ + return foo3c(); +} diff --git a/Tests/Dependency/Case2/foo3.c b/Tests/Dependency/Case2/foo3.c index dacef6a..cab9535 100644 --- a/Tests/Dependency/Case2/foo3.c +++ b/Tests/Dependency/Case2/foo3.c @@ -1,2 +1,5 @@ extern int foo1b(void); -int foo3(void) { return foo1b(); } +int foo3(void) +{ + return foo1b(); +} diff --git a/Tests/Dependency/Case2/foo3b.c b/Tests/Dependency/Case2/foo3b.c index ca25fd8..69d2c8c 100644 --- a/Tests/Dependency/Case2/foo3b.c +++ b/Tests/Dependency/Case2/foo3b.c @@ -1,2 +1,5 @@ extern int foo1c(void); -int foo3b(void) { return foo1c(); } +int foo3b(void) +{ + return foo1c(); +} diff --git a/Tests/Dependency/Case2/foo3c.c b/Tests/Dependency/Case2/foo3c.c index 0ad65fe..e774495 100644 --- a/Tests/Dependency/Case2/foo3c.c +++ b/Tests/Dependency/Case2/foo3c.c @@ -1 +1,4 @@ -int foo3c(void) { return 0; } +int foo3c(void) +{ + return 0; +} diff --git a/Tests/Dependency/Case3/foo1.c b/Tests/Dependency/Case3/foo1.c index 5f1f8ac..d476f2c 100644 --- a/Tests/Dependency/Case3/foo1.c +++ b/Tests/Dependency/Case3/foo1.c @@ -1,2 +1,5 @@ extern int foo2(void); -int foo1(void) { return foo2(); } +int foo1(void) +{ + return foo2(); +} diff --git a/Tests/Dependency/Case3/foo1b.c b/Tests/Dependency/Case3/foo1b.c index 6ae3bab..84933af 100644 --- a/Tests/Dependency/Case3/foo1b.c +++ b/Tests/Dependency/Case3/foo1b.c @@ -1 +1,4 @@ -int foo1b(void) { return 0; } +int foo1b(void) +{ + return 0; +} diff --git a/Tests/Dependency/Case3/foo2.c b/Tests/Dependency/Case3/foo2.c index 33dbbfc..9bbb5d7 100644 --- a/Tests/Dependency/Case3/foo2.c +++ b/Tests/Dependency/Case3/foo2.c @@ -1,2 +1,5 @@ extern int foo1b(void); -int foo2(void) { return foo1b(); } +int foo2(void) +{ + return foo1b(); +} diff --git a/Tests/Dependency/Case4/bar.c b/Tests/Dependency/Case4/bar.c index d0bb0c4..08092f9 100644 --- a/Tests/Dependency/Case4/bar.c +++ b/Tests/Dependency/Case4/bar.c @@ -1,2 +1,5 @@ extern int foo(); -int main() { return foo(); } +int main() +{ + return foo(); +} diff --git a/Tests/Dependency/Case4/foo.c b/Tests/Dependency/Case4/foo.c index 9fe07f8..e05eb7e 100644 --- a/Tests/Dependency/Case4/foo.c +++ b/Tests/Dependency/Case4/foo.c @@ -1 +1,4 @@ -int foo() { return 0; } +int foo() +{ + return 0; +} diff --git a/Tests/Dependency/Case5/bar.c b/Tests/Dependency/Case5/bar.c index 4cb1b1b..fcbd135 100644 --- a/Tests/Dependency/Case5/bar.c +++ b/Tests/Dependency/Case5/bar.c @@ -1,7 +1,7 @@ #ifdef _WIN32 __declspec(dllimport) #endif -void foo(void); + void foo(void); #include <stdio.h> diff --git a/Tests/Dependency/Case5/foo.c b/Tests/Dependency/Case5/foo.c index 794833d..b82b7c2 100644 --- a/Tests/Dependency/Case5/foo.c +++ b/Tests/Dependency/Case5/foo.c @@ -3,7 +3,7 @@ #ifdef _WIN32 __declspec(dllexport) #endif -void foo(void) + void foo(void) { printf("foo()\n"); } diff --git a/Tests/Dependency/Case5/main.c b/Tests/Dependency/Case5/main.c index ae3dc95..a967944 100644 --- a/Tests/Dependency/Case5/main.c +++ b/Tests/Dependency/Case5/main.c @@ -1,6 +1,6 @@ void bar(void); -int main(int argc, char *argv[]) +int main(int argc, char* argv[]) { bar(); return 0; diff --git a/Tests/Dependency/Exec/ExecMain.c b/Tests/Dependency/Exec/ExecMain.c index d2f551c..9572afd 100644 --- a/Tests/Dependency/Exec/ExecMain.c +++ b/Tests/Dependency/Exec/ExecMain.c @@ -5,7 +5,7 @@ void NoDepCFunction(); void SixAFunction(); void SixBFunction(); -int main( ) +int main() { SixAFunction(); SixBFunction(); diff --git a/Tests/Dependency/Exec2/ExecMain.c b/Tests/Dependency/Exec2/ExecMain.c index d08a796..385cce1 100644 --- a/Tests/Dependency/Exec2/ExecMain.c +++ b/Tests/Dependency/Exec2/ExecMain.c @@ -3,7 +3,7 @@ void FiveFunction(); void EightFunction(); -int main( ) +int main() { FiveFunction(); EightFunction(); diff --git a/Tests/Dependency/Exec3/ExecMain.c b/Tests/Dependency/Exec3/ExecMain.c index d08a796..385cce1 100644 --- a/Tests/Dependency/Exec3/ExecMain.c +++ b/Tests/Dependency/Exec3/ExecMain.c @@ -3,7 +3,7 @@ void FiveFunction(); void EightFunction(); -int main( ) +int main() { FiveFunction(); EightFunction(); diff --git a/Tests/Dependency/Exec4/ExecMain.c b/Tests/Dependency/Exec4/ExecMain.c index 3f53573..0cfcce9 100644 --- a/Tests/Dependency/Exec4/ExecMain.c +++ b/Tests/Dependency/Exec4/ExecMain.c @@ -3,7 +3,7 @@ void FiveFunction(); void TwoFunction(); -int main( ) +int main() { FiveFunction(); TwoFunction(); diff --git a/Tests/Dependency/Four/FourSrc.c b/Tests/Dependency/Four/FourSrc.c index 23a66a4..4ea996d 100644 --- a/Tests/Dependency/Four/FourSrc.c +++ b/Tests/Dependency/Four/FourSrc.c @@ -6,7 +6,7 @@ void TwoFunction(); void FourFunction() { static int count = 0; - if( count == 0 ) { + if (count == 0) { ++count; TwoFunction(); } diff --git a/Tests/Dependency/Three/ThreeSrc.c b/Tests/Dependency/Three/ThreeSrc.c index 9c77f17..3e814f3 100644 --- a/Tests/Dependency/Three/ThreeSrc.c +++ b/Tests/Dependency/Three/ThreeSrc.c @@ -4,7 +4,7 @@ void FourFunction(); void ThreeFunction() { static int count = 0; - if( count == 0 ) { + if (count == 0) { ++count; FourFunction(); } diff --git a/Tests/Dependency/Two/TwoSrc.c b/Tests/Dependency/Two/TwoSrc.c index 0b3366b..dbdf524 100644 --- a/Tests/Dependency/Two/TwoSrc.c +++ b/Tests/Dependency/Two/TwoSrc.c @@ -3,7 +3,7 @@ void TwoFunction() { static int count = 0; - if( count == 0 ) { + if (count == 0) { ++count; ThreeFunction(); } |