[PATCH] D124154: [clangd] Fix a declare-constructor tweak crash on incomplete fields.
Haojian Wu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Apr 21 10:51:29 PDT 2022
hokein added inline comments.
================
Comment at: clang-tools-extra/clangd/refactor/tweaks/MemberwiseConstructor.cpp:182
+ if (!C.hasDefinition())
+ return Skip;
// We can't always tell if C is copyable/movable without doing Sema work.
----------------
sammccall wrote:
> Fail instead?
`Fail` seems too strict, the tweak is entirely unavailable if there is any incomplete-type field decls in a class, I think it is still useful to make the tweak available.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D124154/new/
https://reviews.llvm.org/D124154
More information about the cfe-commits
mailing list