[PATCH 3/8] C++fy thread_apply_all_command

Yao Qi qiyaoltc@gmail.com
Thu Apr 13 10:06:00 GMT 2017


Pedro Alves <palves@redhat.com> writes:

> yyyy-mm-dd  Pedro Alves  <palves@redhat.com>
>
> 	* thread.c: Include <algorithm>.
> 	(thread_array_cleanup): Delete.
> 	(scoped_inc_dec_ref): New class.
> 	(live_threads_count): New function.
> 	(set_thread_refcount): Delete.
> 	(tp_array_compar_ascending): Now a bool.
> 	(tp_array_compar): Convert to a std::sort comparison function.
> 	(thread_apply_all_command): Use std::vector and scoped_inc_dec_ref
> 	and live_threads_count.

LGTM.

-- 
Yao (齐尧)



More information about the Gdb-patches mailing list