[PATCH] D50813: [ASTImporter] Add test for IndirectGotoStmt
Raphael Isemann via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Aug 16 11:20:06 PDT 2018
This revision was automatically updated to reflect the committed changes.
Closed by commit rC339915: [ASTImporter] Add test for IndirectGotoStmt (authored by teemperor, committed by ).
Repository:
rC Clang
https://reviews.llvm.org/D50813
Files:
test/Import/indirect-goto/Inputs/F.cpp
test/Import/indirect-goto/test.cpp
Index: test/Import/indirect-goto/test.cpp
===================================================================
--- test/Import/indirect-goto/test.cpp
+++ test/Import/indirect-goto/test.cpp
@@ -0,0 +1,10 @@
+// RUN: clang-import-test -dump-ast -import %S/Inputs/F.cpp -expression %s | FileCheck %s
+
+// CHECK: IndirectGotoStmt
+// CHECK-NEXT: ImplicitCastExpr
+// CHECK-NEXT: DeclRefExpr
+// CHECK-SAME: 'l1_ptr'
+
+void expr() {
+ f();
+}
Index: test/Import/indirect-goto/Inputs/F.cpp
===================================================================
--- test/Import/indirect-goto/Inputs/F.cpp
+++ test/Import/indirect-goto/Inputs/F.cpp
@@ -0,0 +1,6 @@
+void f() {
+ void const *l1_ptr = &&l1;
+ goto *l1_ptr;
+l1:
+ return;
+}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D50813.161072.patch
Type: text/x-patch
Size: 734 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20180816/8713b828/attachment.bin>
More information about the cfe-commits
mailing list