Fix problems introduced with my last change.
[deliverable/binutils-gdb.git] / gdb / gdbtypes.c
index 0d5bee84489df6b126f2ff077b70f3651c9846c2..9909871633d1dc000b8ea5cda18ef5d35a38413a 100644 (file)
@@ -1484,11 +1484,11 @@ check_stub_method (type, method_id, signature_id)
   argtypetext = p;
   while (*p)
     {
-      if (*p == '(')
+      if (*p == '(' || *p == '<')
        {
          depth += 1;
        }
-      else if (*p == ')')
+      else if (*p == ')' || *p == '>')
        {
          depth -= 1;
        }
@@ -1527,11 +1527,11 @@ check_stub_method (type, method_id, signature_id)
              argtypetext = p + 1;
            }
 
-         if (*p == '(')
+         if (*p == '(' || *p == '<')
            {
              depth += 1;
            }
-         else if (*p == ')')
+         else if (*p == ')' || *p == '>')
            {
              depth -= 1;
            }
@@ -2199,6 +2199,16 @@ rank_one_type (parm, arg)
   if (TYPE_CODE (arg) == TYPE_CODE_TYPEDEF)
     arg = check_typedef (arg);
 
+  /*
+     Well, damnit, if the names are exactly the same,
+     i'll say they are exactly the same. This happens when we generate
+     method stubs. The types won't point to the same address, but they
+     really are the same.
+  */
+
+  if (TYPE_NAME (parm) == TYPE_NAME (arg))
+      return 0;
+
   /* Check if identical after resolving typedefs */
   if (parm == arg)
     return 0;
This page took 0.025035 seconds and 4 git commands to generate.