[PATCH] c++: use auto_vec in cp_parser_template_argument_list

2021-11-09 Thread Patrick Palka via Gcc-patches
Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? gcc/cp/ChangeLog: * parser.c (cp_parser_template_argument_list): Use auto_vec instead of manual memory management. --- gcc/cp/parser.c | 35 --- 1 file changed, 8 insertions(+), 27 de

Re: [PATCH] c++: use auto_vec in cp_parser_template_argument_list

2021-11-09 Thread Jason Merrill via Gcc-patches
On 11/9/21 11:02, Patrick Palka wrote: Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? OK, though I wonder about using releasing_vec instead of auto_vec; reusing a previously allocated vec vs. building one on the stack. gcc/cp/ChangeLog: * parser.c (cp_parser_templat

Re: [PATCH] c++: use auto_vec in cp_parser_template_argument_list

2021-11-09 Thread Patrick Palka via Gcc-patches
On Tue, 9 Nov 2021, Jason Merrill wrote: > On 11/9/21 11:02, Patrick Palka wrote: > > Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? > > OK, though I wonder about using releasing_vec instead of auto_vec; reusing a > previously allocated vec vs. building one on the stack. Thanks

Re: [PATCH] c++: use auto_vec in cp_parser_template_argument_list

2021-11-09 Thread Jason Merrill via Gcc-patches
On 11/9/21 13:42, Patrick Palka wrote: On Tue, 9 Nov 2021, Jason Merrill wrote: On 11/9/21 11:02, Patrick Palka wrote: Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? OK, though I wonder about using releasing_vec instead of auto_vec; reusing a previously allocated vec vs. bu

Re: [PATCH] c++: use auto_vec in cp_parser_template_argument_list

2021-11-10 Thread Patrick Palka via Gcc-patches
On Wed, Nov 10, 2021 at 12:16 AM Jason Merrill wrote: > > On 11/9/21 13:42, Patrick Palka wrote: > > On Tue, 9 Nov 2021, Jason Merrill wrote: > > > >> On 11/9/21 11:02, Patrick Palka wrote: > >>> Bootstrapped and regtested on x86_64-pc-linux-gnu, OK for trunk? > >> > >> OK, though I wonder about u