Skip to content

Commit a8de3ee

Browse files
committed
[clang][Interp][NFC] Fix some build warnings
Fixes: /buildbot/worker/arc-folder/llvm-project/clang/lib/AST/Interp/Disasm.cpp:143:25: warning: cast from type 'const clang::interp::Block*' to type 'void*' casts away qualifiers [-Wcast-qual] /buildbot/worker/arc-folder/llvm-project/clang/lib/AST/Interp/Disasm.cpp:271:23: warning: cast from type 'const clang::interp::Block*' to type 'void*' casts away qualifiers [-Wcast-qual]
1 parent 09e7d75 commit a8de3ee

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

clang/lib/AST/Interp/Disasm.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ LLVM_DUMP_METHOD void Program::dump(llvm::raw_ostream &OS) const {
140140
const Descriptor *Desc = G->block()->getDescriptor();
141141
Pointer GP = getPtrGlobal(GI);
142142

143-
OS << GI << ": " << (void *)G->block() << " ";
143+
OS << GI << ": " << (const void *)G->block() << " ";
144144
{
145145
ColorScope SC(OS, true,
146146
GP.isInitialized()
@@ -268,7 +268,7 @@ LLVM_DUMP_METHOD void Record::dump(llvm::raw_ostream &OS, unsigned Indentation,
268268
LLVM_DUMP_METHOD void Block::dump(llvm::raw_ostream &OS) const {
269269
{
270270
ColorScope SC(OS, true, {llvm::raw_ostream::BRIGHT_BLUE, true});
271-
OS << "Block " << (void *)this << "\n";
271+
OS << "Block " << (const void *)this << "\n";
272272
}
273273
unsigned NPointers = 0;
274274
for (const Pointer *P = Pointers; P; P = P->Next) {

0 commit comments

Comments
 (0)