HerrCai0907 added a comment. I cannot find an example that throw `error: expression contains unexpanded parameter pack 'T'` in fold expression because code like ` (foo<T>(10 + (static_cast<U>(1))) + ...);` can be unpack both `T` and `U` in same `...` operator
But this code can be diagnosed correctly template <typename... U> struct A { template <typename... T> void foo(T &&...Params) { (foo<T>(1 + (static_cast<U>(1))) + ...); // ok // error: expression contains unexpanded parameter pack 'T' foo<T>((... + static_cast<U>(1))); (foo<T>((... + static_cast<U>(1))) + ...); // ok } }; Should I add this case into test? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D145892/new/ https://reviews.llvm.org/D145892 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits