[ASTImporter] Test for importing condition variable from a ForStmt

Reviewers: a.sidorin, a_sidorin

Reviewed By: a_sidorin

Subscribers: cfe-commits, martong

Differential Revision: https://reviews.llvm.org/D50928

llvm-svn: 340180
This commit is contained in:
Raphael Isemann 2018-08-20 15:51:41 +00:00
parent 5b06c228af
commit 6ef4fafef8
2 changed files with 14 additions and 0 deletions

View File

@ -3,6 +3,8 @@ void f() {
;
for (int i = 0;;)
continue;
for (; bool j = false;)
continue;
for (int i = 0; i != 0; ++i) {
i++;
}

View File

@ -16,6 +16,18 @@
// CHECK-NEXT: <<NULL>>
// CHECK-NEXT: ContinueStmt
// CHECK: ForStmt
// CHECK-NEXT: <<NULL>>
// CHECK-NEXT: DeclStmt
// CHECK-NEXT: VarDecl
// CHECK-NEXT: CXXBoolLiteralExpr
// CHECK-NEXT: ImplicitCastExpr
// CHECK-NEXT: DeclRefExpr
// CHECK-SAME: 'j'
// CHECK-SAME: 'bool'
// CHECK-NEXT: <<NULL>>
// CHECK-NEXT: ContinueStmt
// CHECK: ForStmt
// CHECK-NEXT: DeclStmt
// CHECK-NEXT: VarDecl