From: Pedro Alves <palves@redhat.com>
To: Martin Galvan <martin.galvan@tallertechnologies.com>,
gdb-patches@sourceware.org, tom@tromey.com
Subject: Re: [PATCH] value: Make accessor methods' parameters const-correct
Date: Wed, 06 Apr 2016 23:36:00 -0000 [thread overview]
Message-ID: <57059D83.2010403@redhat.com> (raw)
In-Reply-To: <1459974933-616-1-git-send-email-martin.galvan@tallertechnologies.com>
On 04/06/2016 09:35 PM, Martin Galvan wrote:
> I did a quick pass over value.c and value.h and made some of the accessor methods'
> parameters const-correct. Besides the obvious benefits, this is required if we
> want to use them on values that are already declared as const (such as the parameters
> to lval_funcs). I also const-ified some of the pass-by-value parameters; while
> they're not as important it's still nice to have them like that.
Thanks for doing this.
Const on pointer parameters is certainly useful. But since you asked
me [ :-) ], I'm on the "const on value params is mostly useless
clutter" camp. It's something you don't see many style guides requiring,
and it's something gdb hasn't been doing either.
So personally I'd prefer a patch without those bits.
>
> There's probably a lot more stuff that can be made const, here and elsewhere.
>
> I have write access and copyright assignment. Ok to commit?
Thanks,
Pedro Alves
next prev parent reply other threads:[~2016-04-06 23:36 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-06 20:36 Martin Galvan
2016-04-06 23:36 ` Pedro Alves [this message]
2016-04-07 13:32 ` Martin Galvan
2016-04-07 13:33 ` Pedro Alves
2016-04-07 13:38 ` Simon Marchi
2016-04-07 13:50 ` Martin Galvan
2016-04-07 14:43 ` Tom Tromey
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=57059D83.2010403@redhat.com \
--to=palves@redhat.com \
--cc=gdb-patches@sourceware.org \
--cc=martin.galvan@tallertechnologies.com \
--cc=tom@tromey.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox