[PATCH] D50550: [ASTImporter] Added test case for opaque enums

Raphael Isemann via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Aug 9 22:22:28 PDT 2018


teemperor updated this revision to Diff 160057.
teemperor added a comment.

- Removed broken FileCheck directive


https://reviews.llvm.org/D50550

Files:
  test/Import/enum/Inputs/S.cpp
  test/Import/enum/test.cpp


Index: test/Import/enum/test.cpp
===================================================================
--- test/Import/enum/test.cpp
+++ test/Import/enum/test.cpp
@@ -1,4 +1,8 @@
-// RUN: clang-import-test -import %S/Inputs/S.cpp -expression %s
+// RUN: clang-import-test -dump-ast -import %S/Inputs/S.cpp -expression %s | FileCheck %s
+
+// CHECK: OpaqueWithType 'long'
+
 void expr() {
   static_assert(E::a + E::b == 3);
+  static_assert(sizeof(OpaqueWithType) == sizeof(long));
 }
Index: test/Import/enum/Inputs/S.cpp
===================================================================
--- test/Import/enum/Inputs/S.cpp
+++ test/Import/enum/Inputs/S.cpp
@@ -2,3 +2,5 @@
   a = 1,
   b = 2
 };
+
+enum OpaqueWithType : long;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D50550.160057.patch
Type: text/x-patch
Size: 726 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180810/466da03e/attachment.bin>


More information about the cfe-commits mailing list