This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA v2 10/17] C++ify mi_parse


On 04/11/2017 04:01 PM, Tom Tromey wrote:
> -  memset (parse, 0, sizeof (*parse));
> +  std::unique_ptr<struct mi_parse> parse (new struct mi_parse);
> +  memset (parse.get (), 0, sizeof (struct mi_parse));
>    parse->all = 0;

The patch made mi_parse be a non-POD (non-trivial dtor), so I
think we should get rid of that memset at the same time.

Thanks,
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]