[clang] ef88536 - [clang][bytecode] Make Boolean::bitcastToMemory const (#215715)
via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 11 23:05:11 PDT 2026
Author: Timm Baeder
Date: 2026-08-12T08:05:05+02:00
New Revision: ef88536bbf62469eb2396d719d237b3191cf4843
URL: https://github.com/llvm/llvm-project/commit/ef88536bbf62469eb2396d719d237b3191cf4843
DIFF: https://github.com/llvm/llvm-project/commit/ef88536bbf62469eb2396d719d237b3191cf4843.diff
LOG: [clang][bytecode] Make Boolean::bitcastToMemory const (#215715)
Added:
Modified:
clang/lib/AST/ByteCode/Boolean.h
Removed:
################################################################################
diff --git a/clang/lib/AST/ByteCode/Boolean.h b/clang/lib/AST/ByteCode/Boolean.h
index 09eefee14a854..a4adcbc6ce008 100644
--- a/clang/lib/AST/ByteCode/Boolean.h
+++ b/clang/lib/AST/ByteCode/Boolean.h
@@ -80,7 +80,9 @@ class Boolean final {
return Boolean(Val);
}
- void bitcastToMemory(std::byte *Buff) { std::memcpy(Buff, &V, sizeof(V)); }
+ void bitcastToMemory(std::byte *Buff) const {
+ std::memcpy(Buff, &V, sizeof(V));
+ }
void print(llvm::raw_ostream &OS) const { OS << (V ? "true" : "false"); }
std::string toDiagnosticString(const ASTContext &Ctx) const {
More information about the cfe-commits
mailing list