[PATCH] D50731: [ASTImporter] Add test for ExprWithCleanups
Raphael Isemann via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 15 15:52:21 PDT 2018
This revision was automatically updated to reflect the committed changes.
Closed by commit rC339830: [ASTImporter] Add test for ExprWithCleanups (authored by teemperor, committed by ).
Repository:
rC Clang
https://reviews.llvm.org/D50731
Files:
test/Import/expr-with-cleanups/Inputs/S.cpp
test/Import/expr-with-cleanups/test.cpp
Index: test/Import/expr-with-cleanups/Inputs/S.cpp
===================================================================
--- test/Import/expr-with-cleanups/Inputs/S.cpp
+++ test/Import/expr-with-cleanups/Inputs/S.cpp
@@ -0,0 +1,8 @@
+struct RAII {
+ int i = 0;
+ RAII() { i++; }
+ ~RAII() { i--; }
+};
+void f() {
+ RAII();
+}
Index: test/Import/expr-with-cleanups/test.cpp
===================================================================
--- test/Import/expr-with-cleanups/test.cpp
+++ test/Import/expr-with-cleanups/test.cpp
@@ -0,0 +1,8 @@
+// RUN: clang-import-test -dump-ast -import %S/Inputs/S.cpp -expression %s | FileCheck %s
+// CHECK: ExprWithCleanups
+// CHECK-SAME: 'RAII'
+// CHECK-NEXT: CXXBindTemporaryExpr
+
+void expr() {
+ f();
+}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D50731.160933.patch
Type: text/x-patch
Size: 755 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180815/571d5a53/attachment.bin>
More information about the cfe-commits
mailing list