[clang] [Clang] Skip past code generation for unevaluated lambdas (PR #124572)

Eli Friedman via cfe-commits cfe-commits at lists.llvm.org
Mon Jan 27 12:00:33 PST 2025


efriedma-quic wrote:

See also discussion on #117845.  I think it makes some sense to add a way for CodeGen to query whether a given declaration is impossible to emit.  I suggested in that discussion that it could be a kind of linkage.

I'd prefer not to mess with the way DeferredDecls works for decls that aren't impossible to emit, if possible.

I don't think "odr-used" is a useful concept here; I think it's possible for an decl to be odr-used even if there isn't a mangling.

Alternatively, we could just invent a mangling here, like we did for #117845.

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


More information about the cfe-commits mailing list