This revision was automatically updated to reflect the committed changes. Closed by commit rC340180: [ASTImporter] Test for importing condition variable from a ForStmt (authored by teemperor, committed by ).
Changed prior to commit: https://reviews.llvm.org/D50928?vs=161342&id=161493#toc Repository: rC Clang https://reviews.llvm.org/D50928 Files: test/Import/for-stmt/Inputs/F.cpp test/Import/for-stmt/test.cpp Index: test/Import/for-stmt/Inputs/F.cpp =================================================================== --- test/Import/for-stmt/Inputs/F.cpp +++ test/Import/for-stmt/Inputs/F.cpp @@ -3,6 +3,8 @@ ; for (int i = 0;;) continue; + for (; bool j = false;) + continue; for (int i = 0; i != 0; ++i) { i++; } Index: test/Import/for-stmt/test.cpp =================================================================== --- test/Import/for-stmt/test.cpp +++ test/Import/for-stmt/test.cpp @@ -17,6 +17,18 @@ // 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 // CHECK-NEXT: IntegerLiteral
Index: test/Import/for-stmt/Inputs/F.cpp =================================================================== --- test/Import/for-stmt/Inputs/F.cpp +++ test/Import/for-stmt/Inputs/F.cpp @@ -3,6 +3,8 @@ ; for (int i = 0;;) continue; + for (; bool j = false;) + continue; for (int i = 0; i != 0; ++i) { i++; } Index: test/Import/for-stmt/test.cpp =================================================================== --- test/Import/for-stmt/test.cpp +++ test/Import/for-stmt/test.cpp @@ -17,6 +17,18 @@ // 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 // CHECK-NEXT: IntegerLiteral
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits