Add langdef arg to la_lookup_symbol_nonlocal.
authorDoug Evans <xdje42@gmail.com>
Tue, 23 Dec 2014 15:24:48 +0000 (07:24 -0800)
committerDoug Evans <xdje42@gmail.com>
Tue, 23 Dec 2014 15:24:48 +0000 (07:24 -0800)
gdb/ChangeLog:

* language.h (struct language_defn) <la_lookup_symbol_nonlocal>:
New arg language_defn.  All uses updated.

gdb/ChangeLog
gdb/ada-lang.c
gdb/cp-namespace.c
gdb/cp-support.h
gdb/language.h
gdb/symtab.c
gdb/symtab.h

index a609cb27bb0b525d2ea82f2f7575d4aa7dfb9a17..28356b8dfe21b50e4eb47ea3ec17c2ed96058f22 100644 (file)
@@ -1,3 +1,8 @@
+2014-12-23  Doug Evans  <xdje42@gmail.com>
+
+       * language.h (struct language_defn) <la_lookup_symbol_nonlocal>:
+       New arg language_defn.  All uses updated.
+
 2014-12-23  Doug Evans  <xdje42@gmail.com>
 
        * symtab.h (SYMBOL_SYMTAB): Delete
index f453ef02d47b2f1e2a99644876bc1c271d48658a..5d4ea2f5c08d491fecbae25b241744ce92836f44 100644 (file)
@@ -5585,7 +5585,8 @@ ada_lookup_symbol (const char *name, const struct block *block0,
 }
 
 static struct symbol *
-ada_lookup_symbol_nonlocal (const char *name,
+ada_lookup_symbol_nonlocal (const struct language_defn *langdef,
+                           const char *name,
                             const struct block *block,
                             const domain_enum domain)
 {
index 0cbf902cdf17139f97c92941edc3ec0c8976177e..6599d45eb0097afe37d192c0e2b4993c049d9288 100644 (file)
@@ -798,7 +798,8 @@ lookup_namespace_scope (const char *name,
    DOMAIN says what kind of symbols we're looking for.  */
 
 struct symbol *
-cp_lookup_symbol_nonlocal (const char *name,
+cp_lookup_symbol_nonlocal (const struct language_defn *langdef,
+                          const char *name,
                           const struct block *block,
                           const domain_enum domain)
 {
index 2594e34cc1e333cfc9f7d68be54e81e54be76d1c..783bdf0b94d0e3bdd839fde48d9bb3d0b11b5aa0 100644 (file)
@@ -192,9 +192,11 @@ extern void cp_add_using_directive (const char *dest,
 extern void cp_scan_for_anonymous_namespaces (const struct symbol *symbol,
                                              struct objfile *objfile);
 
-extern struct symbol *cp_lookup_symbol_nonlocal (const char *name,
-                                                const struct block *block,
-                                                const domain_enum domain);
+extern struct symbol *cp_lookup_symbol_nonlocal
+     (const struct language_defn *langdef,
+      const char *name,
+      const struct block *block,
+      const domain_enum domain);
 
 extern struct symbol *cp_lookup_symbol_namespace (const char *namespace,
                                                  const char *name,
index aa07d8dada0f7945cf1fdb509bcf35c8b6d1db86..2a47e645344bdc9a429e75e4ab833d446b7c90da 100644 (file)
@@ -262,7 +262,8 @@ struct language_defn
        the part of symbol lookup where C looks up static and global
        variables.  */
 
-    struct symbol *(*la_lookup_symbol_nonlocal) (const char *,
+    struct symbol *(*la_lookup_symbol_nonlocal) (const struct language_defn *,
+                                                const char *,
                                                 const struct block *,
                                                 const domain_enum);
 
index 1b9ea068f85a40ce26db981d003e44f20d8ae415..7d2cde5c804a72a129404f96f26bcb5b836bee34 100644 (file)
@@ -1485,7 +1485,7 @@ lookup_symbol_aux (const char *name, const struct block *block,
   /* Now do whatever is appropriate for LANGUAGE to look
      up static and global variables.  */
 
-  sym = langdef->la_lookup_symbol_nonlocal (name, block, domain);
+  sym = langdef->la_lookup_symbol_nonlocal (langdef, name, block, domain);
   if (sym != NULL)
     {
       if (symbol_lookup_debug)
@@ -1805,7 +1805,8 @@ lookup_symbol_via_quick_fns (struct objfile *objfile, int block_index,
 /* See symtab.h.  */
 
 struct symbol *
-basic_lookup_symbol_nonlocal (const char *name,
+basic_lookup_symbol_nonlocal (const struct language_defn *langdef,
+                             const char *name,
                              const struct block *block,
                              const domain_enum domain)
 {
index d19522227b3916eb1aa3b678f94063f6b77b44f6..57ed9fc36e57f1c2225162f6a2f09cf5229fe533 100644 (file)
@@ -1186,9 +1186,11 @@ extern struct symbol *lookup_symbol (const char *, const struct block *,
    that can't think of anything better to do.
    This implements the C lookup rules.  */
 
-extern struct symbol *basic_lookup_symbol_nonlocal (const char *,
-                                                   const struct block *,
-                                                   const domain_enum);
+extern struct symbol *
+  basic_lookup_symbol_nonlocal (const struct language_defn *langdef,
+                               const char *,
+                               const struct block *,
+                               const domain_enum);
 
 /* Some helper functions for languages that need to write their own
    lookup_symbol_nonlocal functions.  */