IDENTIFIER_NODE that happens to look like a typename if it actually
has a type for us to use.
avoid problems w/ SGI STL headers that have variables like __opr or __op1
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@21978
138bc75d-0d04-0410-961f-
82ee72b054a4
+1998-08-25 Brendan Kehoe <brendan@cygnus.com>
+
+ * pt.c (tsubst_copy): Only do typename overloading on an
+ IDENTIFIER_NODE that happens to look like a typename if it actually
+ has a type for us to use.
+
1998-08-25 Jason Merrill <jason@yorick.cygnus.com>
* typeck.c (comp_cv_target_types): Split out...
return tsubst (t, args, in_decl);
case IDENTIFIER_NODE:
- if (IDENTIFIER_TYPENAME_P (t))
+ if (IDENTIFIER_TYPENAME_P (t)
+ /* Make sure it's not just a variable named `__opr', for instance,
+ which can occur in some existing code. */
+ && TREE_TYPE (t))
return build_typename_overload
(tsubst (TREE_TYPE (t), args, in_decl));
else