Commit 3cc35adb authored by Antal Tátrai's avatar Antal Tátrai

Fix compiling clang/libc++ builds. (Issue: #1266)

parent e70f9256
......@@ -548,7 +548,7 @@ class Map {
!defined(GOOGLE_PROTOBUF_OS_NACL) && !defined(GOOGLE_PROTOBUF_OS_ANDROID)
template<class NodeType, class... Args>
void construct(NodeType* p, Args&&... args) {
new (static_cast<void*>(p)) NodeType(std::forward<Args>(args)...);
new (const_cast<void*>(static_cast<const void*>(p))) NodeType(std::forward<Args>(args)...);
}
template<class NodeType>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment