[clang] [clang] Implement a bitwise_copyable builtin type trait. (PR #86512)
Haojian Wu via cfe-commits
cfe-commits at lists.llvm.org
Tue Apr 16 04:49:50 PDT 2024
================
@@ -2667,6 +2667,29 @@ bool QualType::isTriviallyCopyableType(const ASTContext &Context) const {
/*IsCopyConstructible=*/false);
}
+bool QualType::isBitwiseCopyableType(const ASTContext & Context) const {
+ QualType CanonicalType = getCanonicalType();
+ if (CanonicalType->isIncompleteType() || CanonicalType->isDependentType())
----------------
hokein wrote:
Other traits (see `isTriviallyCopyableTypeImpl`) do the similar things for incomplete and dependent types, we follow what they did in this type trait.
https://github.com/llvm/llvm-project/pull/86512
More information about the cfe-commits
mailing list