[PATCH] D26057: [coroutines] Add CoawaitDependentExpr AST node and use it to properly build await_transform.
Eric Fiselier via cfe-commits
cfe-commits at lists.llvm.org
Mon Oct 31 05:55:32 PDT 2016
EricWF added inline comments.
================
Comment at: lib/Sema/SemaCoroutine.cpp:237-244
+static UnresolvedSet<16> lookupOperatorCoawaitCall(Sema &SemaRef, Scope *S,
+ SourceLocation Loc,
+ Expr *E) {
UnresolvedSet<16> Functions;
SemaRef.LookupOverloadedOperatorName(OO_Coawait, S, E->getType(), QualType(),
Functions);
+ return Functions;
----------------
ABataev wrote:
> EricWF wrote:
> > ABataev wrote:
> > > Maybe it is better to add an argument `UnresolvedSetImpl &OpCandidates`?
> > This seems like the best place to specify the concrete type now that everything else uses `UnresolvedSetImpl`.
> Does really matter that it is `UnresolvedSet<16>`, but not `UnresolvedSet<8>` or `UnresolvedSet<4>`? If not, you should not use `UnresolvedSet<16>` as the param type or return type
What matters is that `UnresolvedSetImpl` is an abstract interface and this function returns by value. At some point we have to choose an `N` for `UnresolvedSet<N>` and this is the correct place to do it.
https://reviews.llvm.org/D26057
More information about the cfe-commits
mailing list