Suppress stupid and incorrect MSVC warning. patch from STL@microsoft.com

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@273350 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eric Fiselier 2016-06-22 01:02:08 +00:00
parent c6fcb58914
commit ff58059a86

View File

@ -87,7 +87,11 @@ public:
template <class U> void construct(pointer p, U&& val)
{::new(static_cast<void*>(p)) T(std::forward<U>(val));}
#endif
void destroy(pointer p) {p->~T();}
void destroy(pointer p)
{
p->~T();
((void)p); // Prevent MSVC's spurious unused warning
}
friend bool operator==(const test_allocator& x, const test_allocator& y)
{return x.data_ == y.data_;}
friend bool operator!=(const test_allocator& x, const test_allocator& y)