aboutsummaryrefslogtreecommitdiff
path: root/test/Modules/Inputs/cxx-templates-common.h
diff options
context:
space:
mode:
Diffstat (limited to 'test/Modules/Inputs/cxx-templates-common.h')
-rw-r--r--test/Modules/Inputs/cxx-templates-common.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/test/Modules/Inputs/cxx-templates-common.h b/test/Modules/Inputs/cxx-templates-common.h
index 40a11e20b4f0..682ef939cec0 100644
--- a/test/Modules/Inputs/cxx-templates-common.h
+++ b/test/Modules/Inputs/cxx-templates-common.h
@@ -9,3 +9,30 @@ struct DefinedInCommon {
template<typename T> struct CommonTemplate {
enum E { a = 1, b = 2, c = 3 };
};
+
+namespace Std {
+ template<typename T> struct WithFriend {
+ friend bool operator!=(const WithFriend &A, const WithFriend &B) { return false; }
+ };
+}
+
+namespace Std {
+ template<typename T> void f() {
+ extern T g();
+ }
+}
+
+template<typename T> struct TemplateInstantiationVisibility { typedef int type; };
+
+template<typename T> struct Outer {
+ template<typename U> struct Inner {
+ static constexpr int f();
+ static constexpr int g();
+ };
+};
+
+template<typename T> struct WithPartialSpecialization {};
+typedef WithPartialSpecialization<int*> WithPartialSpecializationUse;
+
+template<typename T> struct WithExplicitSpecialization;
+typedef WithExplicitSpecialization<int> WithExplicitSpecializationUse;