This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA 1/8] Add gdb_ref_ptr.h
- From: Tom Tromey <tom at tromey dot com>
- To: Pedro Alves <palves at redhat dot com>
- Cc: Tom Tromey <tom at tromey dot com>, gdb-patches at sourceware dot org
- Date: Tue, 13 Dec 2016 06:11:06 -0700
- Subject: Re: [RFA 1/8] Add gdb_ref_ptr.h
- Authentication-results: sourceware.org; auth=none
- References: <1480395946-10924-1-git-send-email-tom@tromey.com> <1480395946-10924-2-git-send-email-tom@tromey.com> <13207c13-89b0-c5e3-fbd8-05cc19fda4b2@redhat.com>
>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:
Pedro> BTW, I noticed today that the GCC standards say:
Pedro> "Template parameter names should use CamelCase, following the C++
Pedro> Standard."
Pedro> and they do seem to follow it. I think it's a good idea.
Pedro> Would you mind adjusting accordingly?
No problem, I did that.
FWIW my personal style is also to use CamelCase for macro arguments.
Pedro> I also noticed the "self/other" naming in the global operators:
Pedro> +template<typename T, typename POLICY>
Pedro> +inline bool operator== (const ref_ptr<T, POLICY> &self,
Pedro> + const ref_ptr<T, POLICY> &other)
Pedro> +{
Pedro> I'd find it pedantically more correct to write lhs/rhs, since
Pedro> there's no actual this/self here. Could you tweak that too?
I did this too.
Tom