summaryrefslogtreecommitdiffstats
path: root/Tests/ObjectLibrary
diff options
context:
space:
mode:
authorKitware Robot <kwrobot@kitware.com>2016-05-16 14:34:04 (GMT)
committerBrad King <brad.king@kitware.com>2016-05-16 20:05:19 (GMT)
commitd9fd2f5402eeaa345691313658e02b51038f570b (patch)
treedca71b9a7e267f4c6300da3eb770415381726785 /Tests/ObjectLibrary
parent82df6deaafb36cbbfd450202bb20b320f637751a (diff)
downloadCMake-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/ObjectLibrary')
-rw-r--r--Tests/ObjectLibrary/A/a.h4
-rw-r--r--Tests/ObjectLibrary/A/a2.c5
-rw-r--r--Tests/ObjectLibrary/B/b.h12
-rw-r--r--Tests/ObjectLibrary/B/b1.c5
-rw-r--r--Tests/ObjectLibrary/B/b2.c5
-rw-r--r--Tests/ObjectLibrary/ExportLanguages/a.c5
-rw-r--r--Tests/ObjectLibrary/ExportLanguages/a.cxx5
-rw-r--r--Tests/ObjectLibrary/c.c11
-rw-r--r--Tests/ObjectLibrary/dummy.c5
-rw-r--r--Tests/ObjectLibrary/main.c10
-rw-r--r--Tests/ObjectLibrary/mainAB.c7
11 files changed, 40 insertions, 34 deletions
diff --git a/Tests/ObjectLibrary/A/a.h b/Tests/ObjectLibrary/A/a.h
index 7259f98..b1fd42f 100644
--- a/Tests/ObjectLibrary/A/a.h
+++ b/Tests/ObjectLibrary/A/a.h
@@ -1,6 +1,6 @@
#ifndef A_DEF
-# error "A_DEF not defined"
+#error "A_DEF not defined"
#endif
#ifdef B_DEF
-# error "B_DEF must not be defined"
+#error "B_DEF must not be defined"
#endif
diff --git a/Tests/ObjectLibrary/A/a2.c b/Tests/ObjectLibrary/A/a2.c
index d8f225e..fbb0c02 100644
--- a/Tests/ObjectLibrary/A/a2.c
+++ b/Tests/ObjectLibrary/A/a2.c
@@ -1,2 +1,5 @@
#include "a.h"
-int a2(void) { return 0; }
+int a2(void)
+{
+ return 0;
+}
diff --git a/Tests/ObjectLibrary/B/b.h b/Tests/ObjectLibrary/B/b.h
index 3489c71..a7bd352 100644
--- a/Tests/ObjectLibrary/B/b.h
+++ b/Tests/ObjectLibrary/B/b.h
@@ -1,18 +1,18 @@
#ifdef A_DEF
-# error "A_DEF must not be defined"
+#error "A_DEF must not be defined"
#endif
#ifndef B_DEF
-# error "B_DEF not defined"
+#error "B_DEF not defined"
#endif
#if defined(_WIN32) && defined(Bexport)
-# define EXPORT_B __declspec(dllexport)
+#define EXPORT_B __declspec(dllexport)
#else
-# define EXPORT_B
+#define EXPORT_B
#endif
#if defined(_WIN32) && defined(SHARED_B)
-# define IMPORT_B __declspec(dllimport)
+#define IMPORT_B __declspec(dllimport)
#else
-# define IMPORT_B
+#define IMPORT_B
#endif
diff --git a/Tests/ObjectLibrary/B/b1.c b/Tests/ObjectLibrary/B/b1.c
index fdeffe4..d804d43 100644
--- a/Tests/ObjectLibrary/B/b1.c
+++ b/Tests/ObjectLibrary/B/b1.c
@@ -1,2 +1,5 @@
#include "b.h"
-EXPORT_B int b1(void) { return 0; }
+EXPORT_B int b1(void)
+{
+ return 0;
+}
diff --git a/Tests/ObjectLibrary/B/b2.c b/Tests/ObjectLibrary/B/b2.c
index 6e0d17c..4615b54 100644
--- a/Tests/ObjectLibrary/B/b2.c
+++ b/Tests/ObjectLibrary/B/b2.c
@@ -1,2 +1,5 @@
#include "b.h"
-EXPORT_B int b2(void) { return 0; }
+EXPORT_B int b2(void)
+{
+ return 0;
+}
diff --git a/Tests/ObjectLibrary/ExportLanguages/a.c b/Tests/ObjectLibrary/ExportLanguages/a.c
index af20d3f..1636303 100644
--- a/Tests/ObjectLibrary/ExportLanguages/a.c
+++ b/Tests/ObjectLibrary/ExportLanguages/a.c
@@ -1 +1,4 @@
-int a(void) { return 0; }
+int a(void)
+{
+ return 0;
+}
diff --git a/Tests/ObjectLibrary/ExportLanguages/a.cxx b/Tests/ObjectLibrary/ExportLanguages/a.cxx
index ae9c87c..c661b94 100644
--- a/Tests/ObjectLibrary/ExportLanguages/a.cxx
+++ b/Tests/ObjectLibrary/ExportLanguages/a.cxx
@@ -1 +1,4 @@
-extern "C" int acxx(void) { return 0; }
+extern "C" int acxx(void)
+{
+ return 0;
+}
diff --git a/Tests/ObjectLibrary/c.c b/Tests/ObjectLibrary/c.c
index 968095b..4c37e38 100644
--- a/Tests/ObjectLibrary/c.c
+++ b/Tests/ObjectLibrary/c.c
@@ -1,7 +1,7 @@
#if defined(_WIN32) && defined(Cshared_EXPORTS)
-# define EXPORT_C __declspec(dllexport)
+#define EXPORT_C __declspec(dllexport)
#else
-# define EXPORT_C
+#define EXPORT_C
#endif
extern int a1(void);
@@ -10,10 +10,5 @@ extern int b1(void);
extern int b2(void);
EXPORT_C int c(void)
{
- return 0
- + a1()
- + a2()
- + b1()
- + b2()
- ;
+ return 0 + a1() + a2() + b1() + b2();
}
diff --git a/Tests/ObjectLibrary/dummy.c b/Tests/ObjectLibrary/dummy.c
index 2b17d81..3983c6a 100644
--- a/Tests/ObjectLibrary/dummy.c
+++ b/Tests/ObjectLibrary/dummy.c
@@ -1 +1,4 @@
-int dummy(void) {return 0;}
+int dummy(void)
+{
+ return 0;
+}
diff --git a/Tests/ObjectLibrary/main.c b/Tests/ObjectLibrary/main.c
index 6819f1c..b2f1d44 100644
--- a/Tests/ObjectLibrary/main.c
+++ b/Tests/ObjectLibrary/main.c
@@ -1,16 +1,12 @@
#if defined(_WIN32) && defined(SHARED_C)
-# define IMPORT_C __declspec(dllimport)
+#define IMPORT_C __declspec(dllimport)
#else
-# define IMPORT_C
+#define IMPORT_C
#endif
extern IMPORT_C int b1(void);
extern IMPORT_C int b2(void);
extern IMPORT_C int c(void);
int main(void)
{
- return 0
- + c()
- + b1()
- + b2()
- ;
+ return 0 + c() + b1() + b2();
}
diff --git a/Tests/ObjectLibrary/mainAB.c b/Tests/ObjectLibrary/mainAB.c
index 38db205..a7aa393 100644
--- a/Tests/ObjectLibrary/mainAB.c
+++ b/Tests/ObjectLibrary/mainAB.c
@@ -11,10 +11,7 @@ int main(void)
{
return 0
#ifndef NO_A
- + a1()
- + a2()
+ + a1() + a2()
#endif
- + b1()
- + b2()
- ;
+ + b1() + b2();
}