(root)/
gcc-13.2.0/
gcc/
testsuite/
g++.dg/
template/
pr88795.C
// { dg-do compile { target c++17 } }

template<class, int>
struct Array {};

template<class T, int size_>
struct Foo {
  static constexpr int size() {
      return size_;
  }

  template<class U>
  Foo(U, Array<T, size()>) {}
};

template<class T, int size, class U>
Foo(U, Array<T, size>) -> Foo<T, size>;

int main() {
  Array<int, 2> arr{};

  Foo foo{2.0, arr};
}