[PATCH] D55662: [Sema][ObjC] Do not warn about repeated uses of weak variables when the variables are accessed in an unevaluated context.
John McCall via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Dec 18 21:59:28 PST 2018
rjmccall added a comment.
In D55662#1335402 <https://reviews.llvm.org/D55662#1335402>, @ahatanak wrote:
> Sorry, please ignore my previous comment. I was looking at the wrong place.
> The following code reaches `Sema::BuildDecltypeType` without going through `ActOnDecltypeExpression`:
> template <typename T>
> void overloaded_fn(T);
> decltype(auto) v5 = &overloaded_fn<int>;
> `Sema::BuildDecltypeType` is called from `Sema::DeduceAutoType`, so calling `CheckPlaceholderExpr ` there should fix the assert when the test case above is compiled.
Okay. You may need to push an unevaluated context when doing that.
CHANGES SINCE LAST ACTION
More information about the cfe-commits