Commit ac818bfa authored by Jakub Klinkovský's avatar Jakub Klinkovský
Browse files

Added static assert to the function Cuda::getSharedMemory

parent 34670339
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -116,6 +116,8 @@ struct SharedMemory< T, 64 >
template< typename T >
__device__ inline T* getSharedMemory()
{
   static_assert( sizeof(T) == 1 || sizeof(T) == 2 || sizeof(T) == 4 || sizeof(T) == 8,
                  "Requested type has unsupported size." );
   return SharedMemory< T >{};
}