This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Internal compiler error when mistakenly taking the address of a pure virtual method


At 12:56 11.08.98 , Kalle Dalheimer wrote:
>Hi,
>
>on Linux 2.0.33 Intel, egcs 1.03a, I get an internal compiler error for the
>following (admittedly wrong) code:
>
>class Base
>{
>	virtual bool isSomething() const = 0;
>};
>
>class Derived : public Base
>{
>	virtual bool isSomething() const { return false; }
>};
>
>int main( int argc, char* argv [] )
>{
>	Base* derived = new Derived();
>	bool ret = derived->isSomething; // internal compiler error
>}
>
>When I put the parentheses after isSomething in the last but one line,
>everything is fine.
>
>Just in case, here is the output of g++ -v:
>
>Reading specs from
/usr/local/lib/gcc-lib/i586-pc-linux-gnulibc1/egcs-2.90.29/specs
>gcc version egcs-2.90.29 980515 (egcs-1.0.3 release)   
>
>Hope this helps; let me know if you need further information.

Hi,

if this is kde-1.0 code there's quite a big chance that this is fixed in
egcs-1.1. I've compiled kde-1.0 with the latest snapshots nearly without
problems (a lot of warnings though). The only hard fail was in
kdegames/ksnake so far and some minor problems in kdemultimedia.

I think a lot of non-Intel Linux people would appreciate if KDE would at
least compile with egcs. So please download the latest snapshot (which is
nearly egcs-1.1 already) and test with it.

Franz.



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]