From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Christian II" To: Subject: Is this a bug? Date: Tue, 11 May 1999 21:09:00 -0000 Message-id: <000501be9c2c$c17c5e80$e712fdd1@john> X-SW-Source: 1999-05/msg00231.html List-Id: Is this a bug in the compiler? I am using version 1.1.2 of the egcs compiler; and when I compile the following program in DOS or linux, I get this output: test.cpp: In function `int main()': test.cpp:33: no matching function for call to `Triangle::render (int, int, int)' test.cpp:27: candidates are: Triangle::render() Shouldn't it call Object::render(float, float, float)? Instead, Triangle::render() overrides it! Could you please E-mail me about this at: christianii@prodigy.net // test program class Object { public: virtual void move(float x, float y, float z); virtual void render(); // render at origin void render(float x, float y, float z) // render at x,y,z {move(x,y,z); render(); move(-x,-y,-z);} }; class Triangle { float v[3][3]; public: virtual void move(float x, float y, float z); virtual void render(); }; main() { Triangle t; t.render(0, 0, -5); }