diff options
Diffstat (limited to 'test/Modules/template-default-args.cpp')
-rw-r--r-- | test/Modules/template-default-args.cpp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/Modules/template-default-args.cpp b/test/Modules/template-default-args.cpp new file mode 100644 index 000000000000..63187b8dc190 --- /dev/null +++ b/test/Modules/template-default-args.cpp @@ -0,0 +1,22 @@ +// RUN: rm -rf %t +// RUN: %clang_cc1 -fmodules -verify -fmodules-cache-path=%t -I %S/Inputs/template-default-args -std=c++11 %s +// +// expected-no-diagnostics + +template<typename T> struct A; +template<typename T> struct B; +template<typename T> struct C; +template<typename T = int> struct D; + +#include "b.h" + +template<typename T = int> struct A {}; +template<typename T> struct B {}; +template<typename T = int> struct B; +template<typename T = int> struct C; +template<typename T> struct D {}; + +A<> a; +B<> b; +extern C<> c; +D<> d; |