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: [patch 1/2] Perform a namespace lookup at every block level


>>>>> "Sami" == Sami Wagiaalla <swagiaal@redhat.com> writes:

Sami> I have added shadowing.exp to the patch which belongs to a future
Sami> patch but has some good tests, and it tests for the problem
Sami> pointed out by Daniel. I also added
Sami> namespace-multiple-imports.exp. Excuse the kfails; they will be
Sami> fixed by a future patch.

Thanks.

Sami> +static struct symbol *
Sami> +cp_lookup_symbol_in_namespace (const char *namespace,
Sami> +                   const char *name,
Sami> +                   const char *linkage_name,
Sami> +                   const struct block *block,
Sami> +                   const domain_enum domain)
Sami> +{
Sami> +

Extra blank line.

Sami> +static struct symbol *
Sami> +cp_lookup_symbol_imports (const char *scope,
Sami> +                          const char *name,
Sami> +                          const char *linkage_name,
Sami> +                          const struct block *block,
Sami> +                          const domain_enum domain)
[...]
Sami> +      /* If the import destination is the current scope or one of its ancestors then

Does this line go past column 80?  It looks like it.

Sami> +         it is applicable.  */
Sami> +      if (strncmp (scope, current->import_dest, strlen (current->import_dest)) == 0)

>From my reading this doesn't exactly match the comment -- can
current->import_dest be an extension of scope?  Like, if scope is "x"
and import_dest is "xyz"?

Sami> diff --git a/gdb/testsuite/gdb.cp/namespace-using.exp b/gdb/testsuite/gdb.cp/namespace-using.exp
Sami> +    return -1;

No ";" here.

Otherwise this looks good.

Tom


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