diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2011-07-17 15:40:56 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2011-07-17 15:40:56 +0000 |
commit | 180abc3db9ae3b4fc63cd65b15697e6ffcc8a657 (patch) | |
tree | 2097d084eb235c0b12c0bff3445f4ec7bbaa8a12 /test/SemaTemplate/deduction.cpp | |
parent | 29cafa66ad3878dbb9f82615f19fa0bded2e443c (diff) |
Diffstat (limited to 'test/SemaTemplate/deduction.cpp')
-rw-r--r-- | test/SemaTemplate/deduction.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/SemaTemplate/deduction.cpp b/test/SemaTemplate/deduction.cpp index 15c061c26198f..aecb5ee7c8b3d 100644 --- a/test/SemaTemplate/deduction.cpp +++ b/test/SemaTemplate/deduction.cpp @@ -150,3 +150,15 @@ namespace test3 { } }; } + +// Verify that we can deduce enum-typed arguments correctly. +namespace test14 { + enum E { E0, E1 }; + template <E> struct A {}; + template <E e> void foo(const A<e> &a) {} + + void test() { + A<E0> a; + foo(a); + } +} |