aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorMartin v. Löwis <loewis@informatik.hu-berlin.de>1999-01-24 15:38:44 +0000
committerMartin v. Löwis <loewis@gcc.gnu.org>1999-01-24 15:38:44 +0000
commit347d73d7082681958142dcb57e60f2f45e7f8777 (patch)
tree3f340e3cc3e68990e453f2a59e6650753496f464 /gcc
parent4a050cc23faad32967ab9b813e1e4ae55fe3511e (diff)
downloadgcc-347d73d7082681958142dcb57e60f2f45e7f8777.zip
gcc-347d73d7082681958142dcb57e60f2f45e7f8777.tar.gz
gcc-347d73d7082681958142dcb57e60f2f45e7f8777.tar.bz2
decl.c (decls_match): Return 1 if old and new are identical.
1999-01-25 Martin von Loewis <loewis@informatik.hu-berlin.de> * decl.c (decls_match): Return 1 if old and new are identical. (push_overloaded_decl): Set OVL_USED when PUSH_USING. From-SVN: r24849
Diffstat (limited to 'gcc')
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/decl.c5
2 files changed, 10 insertions, 0 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index ab36217..4a0a402 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,8 @@
+1999-01-25 Martin von Loewis <loewis@informatik.hu-berlin.de>
+
+ * decl.c (decls_match): Return 1 if old and new are identical.
+ (push_overloaded_decl): Set OVL_USED when PUSH_USING.
+
1999-01-24 Jason Merrill <jason@yorick.cygnus.com>
* decl.c (start_function): Make member functions one_only on windows.
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c
index e1e50f6..d622632 100644
--- a/gcc/cp/decl.c
+++ b/gcc/cp/decl.c
@@ -2696,6 +2696,9 @@ decls_match (newdecl, olddecl)
{
int types_match;
+ if (newdecl == olddecl)
+ return 1;
+
if (TREE_CODE (newdecl) != TREE_CODE (olddecl))
/* If the two DECLs are not even the same kind of thing, we're not
interested in their types. */
@@ -4239,6 +4242,8 @@ push_overloaded_decl (decl, flags)
new_binding = ovl_cons (decl, ovl_cons (old, NULL_TREE));
else
new_binding = ovl_cons (decl, old);
+ if (flags & PUSH_USING)
+ OVL_USED (new_binding) = 1;
}
else
/* NAME is not ambiguous. */