kmclaughlin-arm wrote: > > I'm having a bit of trouble understanding the way the new code is structured. > What makes the definition of lambda call operators special here? Do we not > call GetOrCreateLLVMFunction with IsForDefinition set?
When I added this error I incorrectly thought GetOrCreateLLVMFunction is not called with IsForDefinition set. Now that I've taken another look at it, I see that it is set and the reason the existing error is not emitted is because of the `!Entry->isDeclaration()` condition. I have removed most of my changes and instead extended the `isDeclaration()` check to also consider whether this is lambda. I don't think it's correct to remove `isDeclaration()`; I believe this was added to allow a non-C++ declaration with a mangled name matching a C++ function (described in https://reviews.llvm.org/D11297). https://github.com/llvm/llvm-project/pull/107581 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits