[PATCH] D147808: [clangd] Support defaulted destructors in Define Outline tweak

Nathan James via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Apr 14 10:11:51 PDT 2023


njames93 added a comment.

In D147808#4268523 <https://reviews.llvm.org/D147808#4268523>, @kadircet wrote:

> there's actually a slight difference between an inline defaulted special member function and an out-of-line defaulted one. the latter makes the special member "user-defined" which might cause various headaches (e.g. type is no longer "trivial"). i don't think we should make it easy for people to change trivialness of types (especially considering our experience with people thinking anything that comes from the lightbulb is a way to improve your code). on a side node, this is less of an issue in the scenario you described (i.e. when the destructor is virtual, as it already means type is non-trivial).
>
> so if you feel like this is really useful, i guess we can change the scope a little to apply to all special members, but only when type is no longer trivial. WDYT?

That makes sense.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D147808/new/

https://reviews.llvm.org/D147808



More information about the cfe-commits mailing list