https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77927
--- Comment #3 from Jeff Mirwaisi <jeff.mirwaisi at gmail dot com> --- Apologies for the poor bug report, to clarify, unary right folds which use a binary operator in the fold parameter are failing to compile: ( (x op1 y) op2... ); //clearer examples - error: binary expression in operand of fold-expression template<int...N> void f1(){ ((N+1)+...); } template<int...N> void f2(){ ((1+N),...); } template<int...N> void f3(){ ((N-1)*...); } //op1 and op2 do not have to be the same operator //the corresponding left folds compile as expected: template<int...N> void f4(){ (...+(1+N)); }