adding template type to the vector to suppress clang-10 warning that vector may not intend for type deduction.

This commit is contained in:
Jordan Maples 2020-05-29 15:45:25 -07:00
parent 4d2090ebc4
commit 72803a7ecb

View File

@ -1242,7 +1242,7 @@ TEST(span_test, from_array_constructor)
#if (defined(__cpp_deduction_guides) && (__cpp_deduction_guides >= 201611L)) #if (defined(__cpp_deduction_guides) && (__cpp_deduction_guides >= 201611L))
// this test is just to verify that these compile // this test is just to verify that these compile
{ {
std::vector v{1,2,3,4}; std::vector<int> v{1,2,3,4};
gsl::span sp{v}; gsl::span sp{v};
static_assert(std::is_same<decltype(sp), gsl::span<int>>::value); static_assert(std::is_same<decltype(sp), gsl::span<int>>::value);
} }