diff options
author | Douglas Gregor <dgregor@apple.com> | 2008-12-12 07:27:10 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2008-12-12 07:27:10 +0000 |
commit | 93afb0d4f9f2ec322438c3bb7e1114ea6f614510 (patch) | |
tree | f2607f13424e9034e784aa08d0ca7c03064d733e /test/SemaCXX/enum.cpp | |
parent | dcc90d87e6430c643b4311ae5b0089535bca41f7 (diff) |
Add test of enumerator types
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@60940 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaCXX/enum.cpp')
-rw-r--r-- | test/SemaCXX/enum.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/SemaCXX/enum.cpp b/test/SemaCXX/enum.cpp new file mode 100644 index 0000000000..7c44056e49 --- /dev/null +++ b/test/SemaCXX/enum.cpp @@ -0,0 +1,14 @@ +// RUN: clang -fsyntax-only -verify %s + +enum E { + Val1, + Val2 +}; + +int& enumerator_type(int); +float& enumerator_type(E); + +void f() { + E e = Val1; + float& fr = enumerator_type(Val2); +} |