rnk wrote:

> In the testcase, the lambda is just at global scope. Not sure what you're 
> expecting to happen here.

I think that's what I'm trying to get at, this strategy is incomplete and 
didn't work.

I think a principled fix to the general problem would be to incorporate the 
anonymous namespace hash into the names of all internal lambdas. The point 
where we check the lambda mangling number is the point where we know if we have 
an internal or external lambda and decide accordingly:
https://github.com/llvm/llvm-project/blob/11f52f783a64acef671a2b1648a40ba683ad4717/clang/lib/AST/MicrosoftMangle.cpp#L1125

Also this logic has been duplicated, that doesn't seem good:
https://github.com/llvm/llvm-project/blob/11f52f783a64acef671a2b1648a40ba683ad4717/clang/lib/AST/MicrosoftMangle.cpp#L268

To your point, we shouldn't special case vftables, since this solves a more 
general problem of debug info quality.

https://github.com/llvm/llvm-project/pull/71748
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to