diff --git a/tests/ArrayProxy/ArrayProxy.cpp b/tests/ArrayProxy/ArrayProxy.cpp index 31af182d6..8db7f1b8d 100644 --- a/tests/ArrayProxy/ArrayProxy.cpp +++ b/tests/ArrayProxy/ArrayProxy.cpp @@ -22,7 +22,7 @@ #elif defined( __GNUC__ ) # pragma GCC diagnostic ignored "-Wunused-but-set-variable" #else -// unknow compiler... just ignore the warnings for yourselves ;) +// unknown compiler... just ignore the warnings for yourselves ;) #endif #include diff --git a/tests/ArrayProxyNoTemporaries/ArrayProxyNoTemporaries.cpp b/tests/ArrayProxyNoTemporaries/ArrayProxyNoTemporaries.cpp index d1bf1da43..463b156c2 100644 --- a/tests/ArrayProxyNoTemporaries/ArrayProxyNoTemporaries.cpp +++ b/tests/ArrayProxyNoTemporaries/ArrayProxyNoTemporaries.cpp @@ -17,12 +17,12 @@ #if defined( _MSC_VER ) // no need to ignore any warnings with MSVC +#elif defined( __clang__ ) +# pragma clang diagnostic ignored "-Wunused-variable" #elif defined( __GNUC__ ) -# if ( 9 <= __GNUC__ ) -# pragma GCC diagnostic ignored "-Winit-list-lifetime" -# endif +# pragma GCC diagnostic ignored "-Wunused-but-set-variable" #else -// unknow compiler... just ignore the warnings for yourselves ;) +// unknown compiler... just ignore the warnings for yourselves ;) #endif #include diff --git a/tests/ArrayWrapper/ArrayWrapper.cpp b/tests/ArrayWrapper/ArrayWrapper.cpp index 2c48e8838..2a3963c2c 100644 --- a/tests/ArrayWrapper/ArrayWrapper.cpp +++ b/tests/ArrayWrapper/ArrayWrapper.cpp @@ -33,7 +33,9 @@ int main( int /*argc*/, char ** /*argv*/ ) // s1 = aw1; // 'operator =' is ambiguous - vk::ArrayWrapper1D aw2( "foobah" ); + std::string foobah = "foobah"; + + vk::ArrayWrapper1D aw2( foobah ); f( aw2 ); vk::ArrayWrapper1D aw3( { 'f', 'o', 'o', 'b', 'a', 'h' } ); @@ -41,7 +43,7 @@ int main( int /*argc*/, char ** /*argv*/ ) assert( s3.length() == 5 ); std::cout << "<" << s3 << ">" << std::endl; - vk::ArrayWrapper1D aw4( "foobah" ); + vk::ArrayWrapper1D aw4( foobah ); std::string s4 = aw4; assert( s4.length() == 5 ); diff --git a/tests/UniqueHandle/UniqueHandle.cpp b/tests/UniqueHandle/UniqueHandle.cpp index c8de073d9..381086a3c 100644 --- a/tests/UniqueHandle/UniqueHandle.cpp +++ b/tests/UniqueHandle/UniqueHandle.cpp @@ -27,6 +27,19 @@ static std::string EngineName = "Vulkan.hpp"; template class MyAllocator : public std::allocator { +public: + MyAllocator() = default; + + template + MyAllocator( const MyAllocator & /*unused*/ ) + { + } + + template + struct rebind + { + using other = MyAllocator; + }; }; vk::UniqueDescriptorSetLayout createDescriptorSetLayoutUnique( vk::Device const & device,