This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA 10/42] Move some code from buildsym to stabsread
- From: Keith Seitz <keiths at redhat dot com>
- To: Tom Tromey <tom at tromey dot com>, gdb-patches at sourceware dot org
- Date: Thu, 5 Jul 2018 12:16:42 -0700
- Subject: Re: [RFA 10/42] Move some code from buildsym to stabsread
- References: <20180523045851.11660-1-tom@tromey.com> <20180523045851.11660-11-tom@tromey.com>
I just have one comment:
On 05/22/2018 09:58 PM, Tom Tromey wrote:
> diff --git a/gdb/stabsread.c b/gdb/stabsread.c
> index 4cfefaa3e0..13663106dc 100644
> --- a/gdb/stabsread.c
> +++ b/gdb/stabsread.c
> @@ -44,6 +44,7 @@
> #include "target-float.h"
> #include "cp-abi.h"
> #include "cp-support.h"
> +#include "bcache.h"
> #include <ctype.h>
>
> /* Ask stabsread.h to define the vars it normally declares `extern'. */
> @@ -4839,6 +4840,18 @@ find_name_end (const char *name)
> }
> }
>
> +
> +
> +/* Compute a small integer hash code for the given name. */
> +
> +int
> +hashname (const char *name)
> +{
> + return hash (name, strlen (name)) % HASHSIZE;
> +}
> +
> +
> +
> /* Initializer for this module. */
>
> void
Seems some superfluous newlines got pasted in here?
Please use "See stabsread.h" and move the comment into the header.
Okay, that's actually two comments, but one is so trivial, I didn't count it.
Keith