Fix misc-move-const-arg false positives on move-only types.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
clang-tidy/misc/MoveConstantArgumentCheck.cpp | ||
---|---|---|
76 ↗ | (On Diff #97971) | Can we get this from R->hasTrivialCopyConstructor or R->hasNonTrivialCopyConstructor instead of iterating all constructors? |
clang-tidy/misc/MoveConstantArgumentCheck.cpp | ||
---|---|---|
76 ↗ | (On Diff #97971) | Interesting idea, trying R->hasTrivialCopyConstructor() || R->hasNonTrivialCopyConstructor(). |
clang-tidy/misc/MoveConstantArgumentCheck.cpp | ||
---|---|---|
76 ↗ | (On Diff #97971) | I meant the opposite: !R->hasTrivialCopyConstructor() && !R->hasNonTrivialCopyConstructor(). But anyway it doesn't work. We could store another bit for deleted copy constructor, but it wouldn't worth it, if it's needed in this single case. |