================ @@ -188,3 +188,19 @@ void other_main() { static_assert(f<int>() == 2); } } // namespace + + +namespace GH125165 { + +template <typename = void> +auto f(auto t) { + const auto& [...pack] = t; + // expected-error@-1 {{cannot decompose non-class, non-array type 'char const'}} + (pack, ...); +}; + +void g() { + f('x'); // expected-note {{in instantiation}} ---------------- shafik wrote:
Maybe: https://godbolt.org/z/Ejf8Mj5jj https://github.com/llvm/llvm-project/pull/125658 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits