diff options
author | Douglas Gregor <dgregor@apple.com> | 2009-04-13 18:14:40 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2009-04-13 18:14:40 +0000 |
commit | 1daeb69f957e9cb53de55b2baa2f577b8b637963 (patch) | |
tree | 73dc420bec0e24055c2cd9dea420a1f3da278f93 /clang/test/PCH/enum.c | |
parent | 0431504fb2ec74b7f45f6dfcee08a84a8a12c2b8 (diff) | |
download | bcm5719-llvm-1daeb69f957e9cb53de55b2baa2f577b8b637963.tar.gz bcm5719-llvm-1daeb69f957e9cb53de55b2baa2f577b8b637963.zip |
Add PCH support for enumerations and enumerators.
llvm-svn: 68974
Diffstat (limited to 'clang/test/PCH/enum.c')
-rw-r--r-- | clang/test/PCH/enum.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/clang/test/PCH/enum.c b/clang/test/PCH/enum.c new file mode 100644 index 00000000000..92869b6bc83 --- /dev/null +++ b/clang/test/PCH/enum.c @@ -0,0 +1,15 @@ +// Test this without pch. +// RUN: clang-cc -triple=i686-apple-darwin9 -include %S/enum.h -fsyntax-only -verify %s + +// Test with pch. +// RUN: clang-cc -emit-pch -triple=i686-apple-darwin9 -o %t %S/enum.h && +// RUN: clang-cc -triple=i686-apple-darwin9 -include-pch %t -fsyntax-only -verify %s + +int i = Red; + +int return_enum_constant() { + int result = aRoundShape; + return result; +} + +enum Shape s = Triangle; |