================
@@ -3404,6 +3404,15 @@ void CastOperation::CheckBuiltinBitCast() {
return;
}
+ if (SrcExpr.get()->isGLValue() &&
----------------
Nemi26 wrote:
Done, it now uses PerformCopyInitialization to a `const From &`. Global
register variables aren't covered, since the reference binds to them directly
and that's already broken outside bit_cast (#233283).
`From` keeps the operand's qualifiers, as with `std::bit_cast`, so volatile
lvalues are still accepted, and the load is now volatile. Volatile bit-fields
are rejected, as with `std::bit_cast`.
https://github.com/llvm/llvm-project/pull/231830
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits