[clang] [Clang] C++ Templates: Refactor and fix `TransformLambdaExpr`'s mishandling of TypeLocs (PR #78801)

via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 14 10:49:00 PDT 2024


Sirraide wrote:

So as I’ve been looking into this as well, the changes that simplify how `TransformLambdaExpr` make sense (though I think we can go even further here because even `TransformFuncitonProtoType` could probably just take a `bool` and not a callback, but I’ll take another look at that); I’m not convinced we should only create the instantiation scope if it’s a lambda, though, because that seems like it’s only fixing the symptoms of `TransformAttributedType` instantiating the same `FunctionProtoType` twice.

@yuxuanchen1997 If it’s alright with you, currently at least, it’s looking like it’d make more sense if I added (part of) the changes you’ve made here to my branch for this—because I don’t think one fix makes sense w/o the other, so keeping them in separate prs just adds unnecessary complexity to this...

https://github.com/llvm/llvm-project/pull/78801


More information about the cfe-commits mailing list