// A version of alias-decl-79.C where defining-type-id of B and C // are not dependent and instead their vector_size attribute is. // PR c++/115897 // { dg-do compile { target c++11 } } template struct is_same { static constexpr bool value = __is_same(T, U); }; #if __cpp_variable_templates template constexpr bool is_same_v = __is_same(T, U); #endif template struct A; template void f() { using T = float; using B [[gnu::vector_size(N * sizeof(float))]] = T; static_assert(!is_same::value, ""); static_assert(!is_same, A>::value, ""); #if __cpp_variable_templates static_assert(!is_same_v, ""); static_assert(!is_same_v, A>, ""); #endif }; template void g() { using T = float*; using C [[gnu::vector_size(N * sizeof(float*))]] = T; static_assert(!is_same::value, ""); static_assert(!is_same, A>::value, ""); #if __cpp_variable_templates static_assert(!is_same_v, ""); static_assert(!is_same_v, A>, ""); #endif }; template void f<4>(); template void g<4>();