[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2018-03-17 Thread Zhihao Yuan via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC327782: [C++17] Allow an empty expression in an if init statement (authored by lichray, committed by ). Repository: rC Clang https://reviews.llvm.org/D40445 Files: lib/Parse/ParseExprCXX.cpp test/

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2018-03-14 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete added a comment. @rsmith Can you commit please? https://reviews.llvm.org/D40445 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2018-03-14 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. Thanks, LGTM https://reviews.llvm.org/D40445 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listin

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2018-03-14 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 138339. Rakete added a comment. Rebase and ping :) https://reviews.llvm.org/D40445 Files: lib/Parse/ParseExprCXX.cpp test/CXX/stmt.stmt/stmt.select/p3.cpp Index: test/CXX/stmt.stmt/stmt.select/p3.cpp =

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2018-01-05 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 128729. Rakete added a comment. Addressed review comments. I'll write up a patch in the next coming days then :) https://reviews.llvm.org/D40445 Files: lib/Parse/ParseExprCXX.cpp test/CXX/stmt.stmt/stmt.select/p3.cpp Index: test/CXX/stmt.stmt/st

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2018-01-04 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/Parse/ParseExprCXX.cpp:1760 +if (InitStmt && TryConsumeToken(tok::semi)) { + WarnOnInit(); + return ParseCXXCondition(nullptr, Loc, CK); Please create a NullStmt here (`Actions.ActOnNullStmt`), rather th

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2018-01-04 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 128659. Rakete added a comment. Rebased + friendly 2018 ping :) https://reviews.llvm.org/D40445 Files: lib/Parse/ParseExprCXX.cpp test/CXX/stmt.stmt/stmt.select/p3.cpp Index: test/CXX/stmt.stmt/stmt.select/p3.cpp

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2017-11-24 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 124239. Rakete edited the summary of this revision. Rakete added a comment. Added more test coverage for compatibility warnings, and fixed a bug at the same time :). https://reviews.llvm.org/D40445 Files: lib/Parse/ParseExprCXX.cpp test/CXX/

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2017-11-24 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 124237. Rakete marked an inline comment as done. Rakete added a comment. Moved the while test outside of the #ifdef region for better coverage :) https://reviews.llvm.org/D40445 Files: lib/Parse/ParseExprCXX.cpp test/CXX/stmt.stmt/stmt.select

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2017-11-24 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 124236. Rakete added a comment. Addressed final review comments by adding the appropriate warnings that were missing previously. https://reviews.llvm.org/D40445 Files: lib/Parse/ParseExprCXX.cpp test/CXX/stmt.stmt/stmt.select/p3.cpp Index: test

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2017-11-24 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete updated this revision to Diff 124235. Rakete added a comment. Added a test for the switch statement and added full context to the diff. https://reviews.llvm.org/D40445 Files: lib/Parse/ParseExprCXX.cpp test/CXX/stmt.stmt/stmt.select/p3.cpp Index: test/CXX/stmt.stmt/stmt.sel

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2017-11-24 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added a comment. Hi, thanks for working on this! Can you add tests to make sure that this also works with switch statements (which also have this bug), and not with while? Also, it makes it a lot easier to review these patches if you add context lines to the diff. Thanks, Erik

[PATCH] D40445: [C++17] Allow an empty expression in an if init statement

2017-11-24 Thread Nicolas Lesser via Phabricator via cfe-commits
Rakete created this revision. Rakete added a project: clang. This fixes PR35381 . https://reviews.llvm.org/D40445 Files: lib/Parse/ParseExprCXX.cpp test/CXX/stmt.stmt/stmt.select/p3.cpp Index: test/CXX/stmt.stmt/stmt.select/p3.cpp