diff options
author | John Thompson <John.Thompson.JTSoftware@gmail.com> | 2013-03-26 18:17:28 +0000 |
---|---|---|
committer | John Thompson <John.Thompson.JTSoftware@gmail.com> | 2013-03-26 18:17:28 +0000 |
commit | f4120ac76752468767d31da3a90d6dafb3263f30 (patch) | |
tree | 26625afc133b3f1ad57738019aebe24f64ae28da /test/modularize | |
parent | ab81651bbd2f47c51541227ae591aafa7db5e5af (diff) |
Revised per review comments to rename test files and rearrange input files.
git-svn-id: https://llvm.org/svn/llvm-project/clang-tools-extra/trunk@178047 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/modularize')
16 files changed, 30 insertions, 30 deletions
diff --git a/test/modularize/InputProblemsDuplicate/Header1.h b/test/modularize/InputProblemsDuplicate/Header1.h deleted file mode 100644 index ad41bb13..00000000 --- a/test/modularize/InputProblemsDuplicate/Header1.h +++ /dev/null @@ -1,2 +0,0 @@ -// Same decl as in Header2.h. -typedef int TypeInt; diff --git a/test/modularize/InputProblemsDuplicate/Header2.h b/test/modularize/InputProblemsDuplicate/Header2.h deleted file mode 100644 index 938bb22f..00000000 --- a/test/modularize/InputProblemsDuplicate/Header2.h +++ /dev/null @@ -1,2 +0,0 @@ -// Same decl as in Header1.h. -typedef int TypeInt; diff --git a/test/modularize/InputProblemsInconsistent/Header1.h b/test/modularize/InputProblemsInconsistent/Header1.h deleted file mode 100644 index 67629829..00000000 --- a/test/modularize/InputProblemsInconsistent/Header1.h +++ /dev/null @@ -1,4 +0,0 @@ -// Define symbol such that a declaration exists when this header -// is included, but not when Header2.h is included. -#define SYMBOL1 1 -#include "SubHeader.h" diff --git a/test/modularize/InputProblemsInconsistent/Header2.h b/test/modularize/InputProblemsInconsistent/Header2.h deleted file mode 100644 index aa59ff91..00000000 --- a/test/modularize/InputProblemsInconsistent/Header2.h +++ /dev/null @@ -1,3 +0,0 @@ -// Set up so the declaration in SubHeader.h is not defined. -#define SYMBOL2 1 -#include "SubHeader.h" diff --git a/test/modularize/Inputs/DuplicateHeader1.h b/test/modularize/Inputs/DuplicateHeader1.h new file mode 100644 index 00000000..2936b084 --- /dev/null +++ b/test/modularize/Inputs/DuplicateHeader1.h @@ -0,0 +1,2 @@ +// Same decl as in DuplicateHeader2.h. +typedef int TypeInt; diff --git a/test/modularize/Inputs/DuplicateHeader2.h b/test/modularize/Inputs/DuplicateHeader2.h new file mode 100644 index 00000000..cef0ffeb --- /dev/null +++ b/test/modularize/Inputs/DuplicateHeader2.h @@ -0,0 +1,2 @@ +// Same decl as in DuplicateHeader1.h. +typedef int TypeInt; diff --git a/test/modularize/Inputs/InconsistentHeader1.h b/test/modularize/Inputs/InconsistentHeader1.h new file mode 100644 index 00000000..7dfcca94 --- /dev/null +++ b/test/modularize/Inputs/InconsistentHeader1.h @@ -0,0 +1,4 @@ +// Define symbol such that a declaration exists when this header +// is included, but not when InconsistentHeader2.h is included. +#define SYMBOL1 1 +#include "InconsistentSubHeader.h" diff --git a/test/modularize/Inputs/InconsistentHeader2.h b/test/modularize/Inputs/InconsistentHeader2.h new file mode 100644 index 00000000..a2bcae19 --- /dev/null +++ b/test/modularize/Inputs/InconsistentHeader2.h @@ -0,0 +1,3 @@ +// Set up so the declaration in InconsistentSubHeader.h is not defined. +#define SYMBOL2 1 +#include "InconsistentSubHeader.h" diff --git a/test/modularize/InputProblemsInconsistent/SubHeader.h b/test/modularize/Inputs/InconsistentSubHeader.h index 1395e489..92e7d036 100644 --- a/test/modularize/InputProblemsInconsistent/SubHeader.h +++ b/test/modularize/Inputs/InconsistentSubHeader.h @@ -1,4 +1,4 @@ -// Set up so TypeInt only defined during Header1.h include. +// Set up so TypeInt only defined during InconsistentHeader1.h include. #ifdef SYMBOL1 #define SYMBOL 1 #endif diff --git a/test/modularize/InputNoProblems/SomeDecls.h b/test/modularize/Inputs/SomeDecls.h index af4d994d..af4d994d 100644 --- a/test/modularize/InputNoProblems/SomeDecls.h +++ b/test/modularize/Inputs/SomeDecls.h diff --git a/test/modularize/InputNoProblems/SomeTypes.h b/test/modularize/Inputs/SomeTypes.h index 46c4316f..46c4316f 100644 --- a/test/modularize/InputNoProblems/SomeTypes.h +++ b/test/modularize/Inputs/SomeTypes.h diff --git a/test/modularize/NoProblems.cpp b/test/modularize/NoProblems.modularize index ad0a314f..c162b633 100644 --- a/test/modularize/NoProblems.cpp +++ b/test/modularize/NoProblems.modularize @@ -1,5 +1,5 @@ # RUN: modularize %s -x c++ # RUN: modularize -prefix=%p %s -x c++ -InputNoProblems/SomeTypes.h -InputNoProblems/SomeDecls.h +Inputs/SomeTypes.h +Inputs/SomeDecls.h diff --git a/test/modularize/ProblemsDuplicate.cpp b/test/modularize/ProblemsDuplicate.cpp deleted file mode 100644 index 85a29bf4..00000000 --- a/test/modularize/ProblemsDuplicate.cpp +++ /dev/null @@ -1,6 +0,0 @@ -# RUN: modularize %s -x c++ 2>&1 | FileCheck %s - -InputProblemsDuplicate/Header1.h -InputProblemsDuplicate/Header2.h - -# CHECK: error: 'TypeInt' defined at both {{.*}}{{[/\\]}}InputProblemsDuplicate{{[/\\]}}Header1.h:2:13 and {{.*}}{{[/\\]}}InputProblemsDuplicate{{[/\\]}}Header2.h:2:13 diff --git a/test/modularize/ProblemsDuplicate.modularize b/test/modularize/ProblemsDuplicate.modularize new file mode 100644 index 00000000..43469e08 --- /dev/null +++ b/test/modularize/ProblemsDuplicate.modularize @@ -0,0 +1,6 @@ +# RUN: modularize %s -x c++ 2>&1 | FileCheck %s + +Inputs/DuplicateHeader1.h +Inputs/DuplicateHeader2.h + +# CHECK: error: 'TypeInt' defined at both {{.*}}{{[/\\]}}Inputs{{[/\\]}}DuplicateHeader1.h:2:13 and {{.*}}{{[/\\]}}Inputs{{[/\\]}}DuplicateHeader2.h:2:13 diff --git a/test/modularize/ProblemsInconsistent.cpp b/test/modularize/ProblemsInconsistent.cpp deleted file mode 100644 index d7960141..00000000 --- a/test/modularize/ProblemsInconsistent.cpp +++ /dev/null @@ -1,10 +0,0 @@ -# RUN: modularize %s -x c++ 2>&1 | FileCheck %s - -InputProblemsInconsistent/Header1.h -InputProblemsInconsistent/Header2.h - -# CHECK: error: 'SYMBOL' defined at both {{.*}}{{[/\\]}}InputProblemsInconsistent{{[/\\]}}SubHeader.h:3:9 and {{.*}}{{[/\\]}}InputProblemsInconsistent/SubHeader.h:6:9 -# CHECK-NEXT: error: header '{{.*}}{{[/\\]}}InputProblemsInconsistent{{[/\\]}}SubHeader.h' has different contents dependening on how it was included -# CHECK-NEXT: note: 'SYMBOL' in {{.*}}{{[/\\]}}InputProblemsInconsistent{{[/\\]}}SubHeader.h at 3:9 not always provided -# CHECK-NEXT: note: 'SYMBOL' in {{.*}}{{[/\\]}}InputProblemsInconsistent{{[/\\]}}SubHeader.h at 6:9 not always provided -# CHECK-NEXT: note: 'TypeInt' in {{.*}}{{[/\\]}}InputProblemsInconsistent{{[/\\]}}SubHeader.h at 10:13 not always provided diff --git a/test/modularize/ProblemsInconsistent.modularize b/test/modularize/ProblemsInconsistent.modularize new file mode 100644 index 00000000..dfe03208 --- /dev/null +++ b/test/modularize/ProblemsInconsistent.modularize @@ -0,0 +1,10 @@ +# RUN: modularize %s -x c++ 2>&1 | FileCheck %s + +Inputs/InconsistentHeader1.h +Inputs/InconsistentHeader2.h + +# CHECK: error: 'SYMBOL' defined at both {{.*}}{{[/\\]}}Inputs{{[/\\]}}InconsistentSubHeader.h:3:9 and {{.*}}{{[/\\]}}Inputs/InconsistentSubHeader.h:6:9 +# CHECK-NEXT: error: header '{{.*}}{{[/\\]}}Inputs{{[/\\]}}InconsistentSubHeader.h' has different contents dependening on how it was included +# CHECK-NEXT: note: 'SYMBOL' in {{.*}}{{[/\\]}}Inputs{{[/\\]}}InconsistentSubHeader.h at 3:9 not always provided +# CHECK-NEXT: note: 'SYMBOL' in {{.*}}{{[/\\]}}Inputs{{[/\\]}}InconsistentSubHeader.h at 6:9 not always provided +# CHECK-NEXT: note: 'TypeInt' in {{.*}}{{[/\\]}}Inputs{{[/\\]}}InconsistentSubHeader.h at 10:13 not always provided |