tiemann@arkesden.eng.sun.com (Michael Tiemann) (11/28/89)
Posted-Date: Mon, 27 Nov 89 14:57:31 CST Date: Mon, 27 Nov 89 14:57:31 CST From: vaughan%cadillac.cad.mcc.com@mcc.com (Paul Vaughan) To: bug-g++@prep.ai.mit.edu Subject: inherited public overloaded method bug The following file produces the error message shown below ------------------- class A { public: void foo(int); }; void A::foo(int) {} // line 6 class B : public A {}; class C : public B {}; class D : public C { public: void foo(); }; void D::foo() { foo(4); // line 17 } main() { D d; } This bug was caused by a typo: arkesden% diff -c2 cplus-tree.c~ cplus-tree.c *** cplus-tree.c~ Sat Nov 25 11:17:51 1989 --- cplus-tree.c Mon Nov 27 21:47:29 1989 *************** *** 700,704 **** t = tree_cons (purpose, value, chain); TREE_VIA_PUBLIC (t) = via_public; ! TREE_VIA_PUBLIC (t) = via_virtual; hashcode = list_hash (t); t = list_hash_canon (hashcode, t); --- 700,704 ---- t = tree_cons (purpose, value, chain); TREE_VIA_PUBLIC (t) = via_public; ! TREE_VIA_VIRTUAL (t) = via_virtual; hashcode = list_hash (t); t = list_hash_canon (hashcode, t); arkesden% Michael