[PATCH] D38366: Fix a warning about casting a const pointer to void*
Nikolai Bozhenov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Sep 28 09:04:54 PDT 2017
n.bozhenov created this revision.
https://reviews.llvm.org/rL314336 introduced a new compile time warning about casting a const pointer to void*. Because of that the compiler fails to be built with `-Werror` flag. The suggested patch fixes the issue.
https://reviews.llvm.org/D38366
Files:
clang/lib/AST/ExternalASTMerger.cpp
Index: clang/lib/AST/ExternalASTMerger.cpp
===================================================================
--- clang/lib/AST/ExternalASTMerger.cpp
+++ clang/lib/AST/ExternalASTMerger.cpp
@@ -212,7 +212,7 @@
}
if (!DidCallback && LoggingEnabled())
logs() << "(ExternalASTMerger*)" << (void*)this
- << " asserting for (DeclContext*)" << (void*)DC
+ << " asserting for (DeclContext*)" << (const void*)DC
<< ", (ASTContext*)" << (void*)&Target.AST
<< "\n";
assert(DidCallback && "Couldn't find a source context matching our DC");
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D38366.117001.patch
Type: text/x-patch
Size: 604 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20170928/298b9d56/attachment.bin>
More information about the cfe-commits
mailing list