tree.c (dependent_name): OFFSET_REF and BASELINK are not dependent names.
authorJason Merrill <jason@redhat.com>
Fri, 23 Dec 2011 22:00:02 +0000 (17:00 -0500)
committerJason Merrill <jason@gcc.gnu.org>
Fri, 23 Dec 2011 22:00:02 +0000 (17:00 -0500)
* tree.c (dependent_name): OFFSET_REF and BASELINK
are not dependent names.

From-SVN: r182667

gcc/cp/ChangeLog
gcc/cp/tree.c

index 03040e13af7ab6e6d911878b70163066f513628b..10182fcdd1b2491c3e2d353af938263389eee20f 100644 (file)
@@ -1,3 +1,8 @@
+2011-12-23  Jason Merrill  <jason@redhat.com>
+
+       * tree.c (dependent_name): OFFSET_REF and BASELINK
+       are not dependent names.
+
 2011-12-21  Jason Merrill  <jason@redhat.com>
 
        PR c++/51611
index 634c2674b5cce0144064b8cc6b974316c5070fc1..dea7632d829c0047b4fed50f91fb6542cc691c51 100644 (file)
@@ -1463,6 +1463,8 @@ dependent_name (tree x)
   if (TREE_CODE (x) == IDENTIFIER_NODE)
     return x;
   if (TREE_CODE (x) != COMPONENT_REF
+      && TREE_CODE (x) != OFFSET_REF
+      && TREE_CODE (x) != BASELINK
       && is_overloaded_fn (x))
     return DECL_NAME (get_first_fn (x));
   return NULL_TREE;