1 //===----------------------------------------------------------------------===// 2 // 3 // The LLVM Compiler Infrastructure 4 // 5 // This file is dual licensed under the MIT and the University of Illinois Open 6 // Source Licenses. See LICENSE.TXT for details. 7 // 8 //===----------------------------------------------------------------------===// 9 10 // <array> 11 // UNSUPPORTED: c++98, c++03, c++11, c++14 12 // UNSUPPORTED: libcpp-no-deduction-guides 13 14 15 // template <class T, class... U> 16 // array(T, U...) -> array<T, 1 + sizeof...(U)>; 17 // 18 // Requires: (is_same_v<T, U> && ...) is true. Otherwise the program is ill-formed. 19 20 21 #include <array> 22 #include <cassert> 23 #include <cstddef> 24 25 #include "test_macros.h" 26 27 int main() 28 { 29 { 30 std::array arr{1,2,3L}; // expected-error {{no viable constructor or deduction guide for deduction of template arguments of 'array'}} 31 } 32 } 33