]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
commit c92bdb809c286916b2ee6c267dad6a58a5706a62
authorJan Kratochvil <jan.kratochvil@redhat.com>
Sat, 2 Jul 2011 20:13:12 +0000 (20:13 +0000)
committerJan Kratochvil <jan.kratochvil@redhat.com>
Sat, 2 Jul 2011 20:13:12 +0000 (20:13 +0000)
Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Date:   Fri Jul 1 20:27:58 2011 +0000

gdb/
* linespec.c (find_method): Accept the function type automatically only
if it was specified with parameter types.

gdb/testsuite/
* gdb.cp/paren-type.cc: New files.
* gdb.cp/paren-type.exp: New files.

gdb/ChangeLog
gdb/linespec.c
gdb/testsuite/ChangeLog

index aeaadcf693105d2b2049f61ccd0fc330bbdcdd1c..8cdb092f5a16b6c9a61c87c1952e7924559afd03 100644 (file)
@@ -1,3 +1,8 @@
+2011-07-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+       * linespec.c (find_method): Accept the function type automatically only
+       if it was specified with parameter types.
+
 2011-07-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
 
        Stop on first linespec terminator instead of eating what we can.
index fe3208d420ac6bd7ca84f602a42249e95b9a4dc4..972fb47e0c3e3301303f9e339f5644655b34ab70 100644 (file)
@@ -1696,7 +1696,10 @@ find_method (int funfirstline, struct linespec_result *canonical,
   i1 = find_methods (t, copy, SYMBOL_LANGUAGE (sym_class), sym_arr,
                     file_symtab);
 
-  if (i1 == 1)
+  /* If we were given a specific overload instance in COPY, defer the field
+     acceptance till the strcmp_iw verification below, even if we found just
+     a single field with that name.  */
+  if (i1 == 1 && strchr (copy, '(') == NULL)
     {
       /* There is exactly one field with that name.  */
       sym = sym_arr[0];
index 48b69eafffac10576c77e68e9e69b63df756bb78..9f523e8586bfdeb185a30fb62360104abd190be6 100644 (file)
@@ -1,3 +1,8 @@
+2011-07-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
+
+       * gdb.cp/paren-type.cc: New files.
+       * gdb.cp/paren-type.exp: New files.
+
 2011-07-02  Jan Kratochvil  <jan.kratochvil@redhat.com>
 
        Stop on first linespec terminator instead of eating what we can.