aboutsummaryrefslogtreecommitdiff
path: root/test/SemaTemplate/instantiate-enum-2.cpp
diff options
context:
space:
mode:
authorEli Friedman <eli.friedman@gmail.com>2009-12-11 01:34:50 +0000
committerEli Friedman <eli.friedman@gmail.com>2009-12-11 01:34:50 +0000
commited0716b7b79d8cdef34f3bd35776a91aa3c943e5 (patch)
tree13b959369d1879d76e0c5900bf0128b4efea01ee /test/SemaTemplate/instantiate-enum-2.cpp
parentd6baec80f2e7763bbcc9aefd7eaa1580223b1389 (diff)
Fix the handling of dependent enums per C++ DR 502.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91089 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaTemplate/instantiate-enum-2.cpp')
-rw-r--r--test/SemaTemplate/instantiate-enum-2.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/SemaTemplate/instantiate-enum-2.cpp b/test/SemaTemplate/instantiate-enum-2.cpp
new file mode 100644
index 0000000000..2b56a036e9
--- /dev/null
+++ b/test/SemaTemplate/instantiate-enum-2.cpp
@@ -0,0 +1,9 @@
+// RUN: clang-cc %s -fsyntax-only -verify
+
+template<int IntBits> struct X {
+ enum {
+ IntShift = (unsigned long long)IntBits,
+ ShiftedIntMask = (1 << IntShift)
+ };
+};
+X<1> x;