Files
clang-p2996/clang/lib/Sema/SemaDeclCXX.cpp
Hans Wennborg a4fbc09184 Clang: Don't warn about unused private fields of types declared maybe_unused
The compiler should not warn on code such as:

  class [[maybe_unused]] MaybeUnusedClass {};
  class C {
    MaybeUnusedClass c;
  };

Patch based on comments on the bug by Shafik and Aaron.

Fixes #61334

Differential revision: https://reviews.llvm.org/D159083
2023-08-30 09:06:39 +02:00

724 KiB