[PATCH] D121532: [Clang][WIP] Fix Unevaluated Lambdas

Corentin Jabot via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Mar 14 07:35:32 PDT 2022


cor3ntin added inline comments.


================
Comment at: clang/lib/Sema/TreeTransform.h:12948
+
+  if (OldClass->isDependentContext())
+    getDerived().transformedLocalDecl(OldClass, {Class});
----------------
aaron.ballman wrote:
> Can you explain why you only do these transformations when the old class is a dependent context? Also, should this be looking at `getDerived().AlwaysRebuild()`? I'm not certain -- we're not calling any `Rebuild*` functions here because lambdas are not rebuilt but generated entirely from scratch. So I'm guessing we don't need to look at `AlwaysRebuild`, but it's a bit unclear.
I was trying to fix some crashes at some point, Not sure that's still needed anymore, I have to check. I suspect you might be right.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D121532/new/

https://reviews.llvm.org/D121532



More information about the cfe-commits mailing list