[clang] [clang][ExprConst] Diagnose out-of-lifetime access consistently (PR #175562)
Timm Baeder via cfe-commits
cfe-commits at lists.llvm.org
Mon Jan 12 21:09:31 PST 2026
tbaederr wrote:
> We should probably add a note to `constexpr int b = b;` explicitly noting that "b" is the object we're trying to initialize, but we leave that for a followup.
This is diagnosed here:
https://github.com/llvm/llvm-project/blob/a0e0775d91859d6ca32efc5fb8644b6281e98593/clang/lib/AST/ExprConstant.cpp#L4265-L4267
where `O` is unfortunately `None`. So there's nothing simple we can do as far as I can see.
https://github.com/llvm/llvm-project/pull/175562
More information about the cfe-commits
mailing list