https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109756
Jakub Jelinek <jakub at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jakub at gcc dot gnu.org --- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> --- The https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2022/p1774r8.pdf paper says in the introductory part: We could therefore hypothetically permit the assume attribute to directly support pack expansion: template <int... args> void f() { [[assume(args >= 0)...]]; } However, we do not propose this. It would require substantial additional work for a very rare use case. Note that this can instead be expressed with a fold expression, which is equivalent to the above and works out of the box without any extra effort: template <int... args> void f() { [[assume(((args >= 0) && ...))]]; } http://eel.is/c++draft/dcl.attr#grammar-4 says: "In an attribute-list, an ellipsis may appear only if that attribute's specification permits it." And I don't see it being explicitly permitted for any of the standard attribute (except for alignas which uses a different syntax). So, I think this is invalid and we should reject it.