[PATCH] D43357: [Concepts] Function trailing requires clauses

2020-01-09 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. This breaks tests on Windows: http://45.33.8.238/win/5368/step_7.txt Please take a look and revert if it takes a while to investigate. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D43357/new/

[PATCH] D43357: [Concepts] Function trailing requires clauses

2020-01-08 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, I'm happy to iterate on this further after you commit (though feel free to ask for another round of review if you prefer). The changes to recovery from missing parens in a trailing

[PATCH] D43357: [Concepts] Function trailing requires clauses

2020-01-08 Thread Saar Raz via Phabricator via cfe-commits
saar.raz marked an inline comment as done. saar.raz added inline comments. Comment at: clang/lib/Sema/SemaOverload.cpp:6340-6347 if (!AllowExplicit) { ExplicitSpecifier ES = ExplicitSpecifier::getFromDecl(Function); if (ES.getKind() !=

[PATCH] D43357: [Concepts] Function trailing requires clauses

2020-01-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang/lib/Sema/SemaTemplateDeduction.cpp:3440-3447 + // C++2a [temp.deduct]p5 + // [...] When all template arguments have been deduced [...] all uses of + // template parameters [...] are replaced with the corresponding deduced +

[PATCH] D43357: [Concepts] Function trailing requires clauses

2020-01-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith marked an inline comment as done. rsmith added inline comments. Comment at: clang/include/clang/AST/ASTNodeTraverser.h:391-392 +if (const Expr *TRC = D->getTrailingRequiresClause()) + Visit(TRC); + It would be better to do this before we visit

[PATCH] D43357: [Concepts] Function trailing requires clauses

2019-12-20 Thread Saar Raz via Phabricator via cfe-commits
saar.raz added inline comments. Comment at: clang/lib/Parse/ParseDecl.cpp:2068-2069 if (ParseAsmAttributesAfterDeclarator(D)) return nullptr; rsmith wrote: > We should check with GCC to see which side of the requires-clause they expect > this. > >

[PATCH] D43357: [Concepts] Function trailing requires clauses

2019-12-14 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: clang/include/clang/Basic/DiagnosticParseKinds.td:179-180 def err_unexpected_semi : Error<"unexpected ';' before %0">; +def err_expected_primary_got_unary : Error< + "expected primary expression before %0; did you forget

[PATCH] D43357: [Concepts] Function trailing requires clauses

2019-04-23 Thread Gabor Marton via Phabricator via cfe-commits
martong accepted this revision. martong added a comment. This revision is now accepted and ready to land. From the `ASTImporter` point of view it looks good, thanks for the changes! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D43357/new/

[PATCH] D43357: [Concepts] Function trailing requires clauses

2019-04-16 Thread Gabor Marton via Phabricator via cfe-commits
martong requested changes to this revision. martong added inline comments. This revision now requires changes to proceed. Comment at: lib/AST/ASTImporter.cpp:3053 +D->isInlineSpecified(), D->isImplicit(), D->isConstexpr(), +InheritedConstructor(),

[PATCH] D43357: [Concepts] Function trailing requires clauses

2018-08-07 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/Sema/SemaDecl.cpp:8377-8381 + } else if (D.hasTrailingRequiresClause()) { +// C++2a [class.virtual]p6 +// A virtual method shall not have a requires-clause. +

[PATCH] D43357: [Concepts] Function trailing requires clauses

2018-08-07 Thread Saar Raz via Phabricator via cfe-commits
saar.raz added inline comments. Comment at: lib/Sema/SemaDecl.cpp:8377-8381 + } else if (D.hasTrailingRequiresClause()) { +// C++2a [class.virtual]p6 +// A virtual method shall not have a requires-clause. +

[PATCH] D43357: [Concepts] Function trailing requires clauses

2018-08-06 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Looking promising, but this patch will need some rework: you need to track the trailing requires clause on the `Declarator` itself, not on the `DeclChunk`, because it's not part of the `DeclChunk` (and may appear in contexts where there is no function chunk).

[PATCH] D43357: [Concepts] Function trailing requires clauses

2018-08-06 Thread Saar Raz via Phabricator via cfe-commits
saar.raz updated this revision to Diff 159349. saar.raz added a comment. Herald added a subscriber: jfb. - Fix bad diagnostic detection and suppression Repository: rC Clang https://reviews.llvm.org/D43357 Files: include/clang/AST/Decl.h include/clang/AST/DeclCXX.h

[PATCH] D43357: [Concepts] Function trailing requires clauses

2018-05-16 Thread Saar Raz via Phabricator via cfe-commits
saar.raz updated this revision to Diff 147188. saar.raz added a comment. - Fixed handling of empty/non-expression after trailing requires keyword. - Unified satisfaction check for templated/non-templated constraint exprs Repository: rC Clang https://reviews.llvm.org/D43357 Files: