[cfe-commits] Handle ExprWithCleanups when creating goto scopes

Rafael EspĂ­ndola rafael.espindola at gmail.com
Tue Oct 2 16:31:43 PDT 2012


> If you check out CGExpr.cpp's EmitExprForReferenceBinding(), it handles all of the cases where we can end up extending the lifetime of a temporary. I suggest following that, rather than trying to halt an arbitrary RecursiveASTVisitor.

There are lots of cases :-(
I decided to try to refactor and share the code. While it works, I
don't have a good name for the auxiliary functions.

I have split the patch in 3 to try to make it easier to see what is going on.

>         - Doug

Cheers,
Rafael
-------------- next part --------------
A non-text attachment was scrubbed...
Name: t1.patch
Type: application/octet-stream
Size: 6996 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20121002/90383c5e/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: t2.patch
Type: application/octet-stream
Size: 6572 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20121002/90383c5e/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: t3.patch
Type: application/octet-stream
Size: 12061 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20121002/90383c5e/attachment-0002.obj>


More information about the cfe-commits mailing list