[PATCH] D146358: [clang][AST] Print name instead of type when diagnosing uninitialized subobject in constexpr variables
Shafik Yaghmour via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sat Mar 18 12:59:41 PDT 2023
shafik added inline comments.
================
Comment at: clang/lib/AST/Interp/Interp.cpp:373
+ const FieldDecl *SubObjDecl) {
+ S.FFDiag(SI, diag::note_constexpr_uninitialized) << SubObjDecl;
+ S.Note(SubObjDecl->getLocation(),
----------------
shafik wrote:
> Do we need to check that `SubObjDecl` is not `nullptr` ever?
If we are sure it can never be `nullptr` then we should `assert(SubObjDecl)`
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D146358/new/
https://reviews.llvm.org/D146358
More information about the cfe-commits
mailing list