This is an archive of the discontinued LLVM Phabricator instance.

[coroutines] Skip over passthrough operator co_await
ClosedPublic

Authored by GorNishanov on Apr 3 2017, 2:08 PM.

Details

Reviewers
EricWF
rsmith

Diff Detail

Event Timeline

GorNishanov created this revision.Apr 3 2017, 2:08 PM
GorNishanov added a reviewer: rsmith.
rsmith accepted this revision.May 22 2017, 12:56 PM

Does it still make sense for us to have a UO_Coawait at all? As I recall, the only purpose it ever had was to represent a dependent co_await expression that couldn't yet be resolved to a CoawaitExpr. But now we have (and need!) a separate DependentCoawaitExpr node to store unqualified lookup results, it seems that the UnaryOperator portion of the representation serves no purpose (and as seen in this patch, it's getting in the way). Can we remove it?

Anyway, this change LGTM for now.

lib/CodeGen/CGCoroutine.cpp
146

paththrough -> passthrough

148–149

Indent.

This revision is now accepted and ready to land.May 22 2017, 12:56 PM

Does it still make sense for us to have a UO_Coawait at all? As I recall, the only purpose it ever had was to represent a dependent co_await expression that couldn't yet be resolved to a CoawaitExpr. But now we have (and need!) a separate DependentCoawaitExpr node to store unqualified lookup results, it seems that the UnaryOperator portion of the representation serves no purpose (and as seen in this patch, it's getting in the way). Can we remove it?

Anyway, this change LGTM for now.

Thank you for the review!
I'll see if I can remove UO_Coawait in a separate patch

GorNishanov closed this revision.May 22 2017, 10:26 PM

r303605 = b026b234d55d6b9fab849389b2085204f530af5d