Re: [PATCH v3] c++: Handle auto(x) in parameter-declaration-clause [PR103401]

2021-12-08 Thread Jason Merrill via Gcc-patches
On 12/8/21 13:32, Marek Polacek wrote: On Wed, Dec 08, 2021 at 09:15:05AM -0500, Jason Merrill wrote: On 12/7/21 19:25, Marek Polacek wrote: On Mon, Dec 06, 2021 at 04:44:06PM -0500, Jason Merrill wrote: Please also make this change to cp_parser_sizeof_operand, and add tests involving

Re: [PATCH v3] c++: Handle auto(x) in parameter-declaration-clause [PR103401]

2021-12-08 Thread Marek Polacek via Gcc-patches
On Wed, Dec 08, 2021 at 09:15:05AM -0500, Jason Merrill wrote: > On 12/7/21 19:25, Marek Polacek wrote: > > On Mon, Dec 06, 2021 at 04:44:06PM -0500, Jason Merrill wrote: > > > Please also make this change to cp_parser_sizeof_operand, and add tests > > > involving sizeof/alignof in array bounds.

Re: [PATCH v3] c++: Handle auto(x) in parameter-declaration-clause [PR103401]

2021-12-08 Thread Jason Merrill via Gcc-patches
On 12/7/21 19:25, Marek Polacek wrote: On Mon, Dec 06, 2021 at 04:44:06PM -0500, Jason Merrill wrote: Please also make this change to cp_parser_sizeof_operand, and add tests involving sizeof/alignof in array bounds. OK with that change. Turns out we reject sizeof(auto(4)) because

[PATCH v3] c++: Handle auto(x) in parameter-declaration-clause [PR103401]

2021-12-07 Thread Marek Polacek via Gcc-patches
On Mon, Dec 06, 2021 at 04:44:06PM -0500, Jason Merrill wrote: > Please also make this change to cp_parser_sizeof_operand, and add tests > involving sizeof/alignof in array bounds. OK with that change. Turns out we reject sizeof(auto(4)) because cp_parser_type_id_1 errors "invalid use of auto".