Date: Wed, 13 Jan 1999 20:03:59 +0600 (OS) From: Eugeny Kuzakov <kev@lab321.ru> To: current@FreeBSD.ORG Subject: Re: g++ bug ? Message-ID: <Pine.BSF.4.02.9901131959120.1265-100000@lab321.ru> In-Reply-To: <Pine.BSF.4.02.9901062138010.9746-100000@lab321.ru>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 6 Jan 1999, Eugeny Kuzakov wrote: hi! Today I am just downloaded and installed 3.0.0-19990105-SNAP.. g++ from snap works Ok. also I have compiled from ports gcc 2.8.1. After install snap ( just run install.sh from all subdirs) g++ 2.8.1 now also work correctly. Very strange..I can not understand it... > I tryed to compile this code ( it uses in groff configure): > #include "confdefs.h" > #ifdef __cplusplus > extern "C" void exit(int); > #endif > > extern "C" { > void _exit(int); > } > int i; > struct A { > char dummy; > A() { i = 1; } > ~A() { if (i == 1) _exit(0); } > }; > A a; > int main() { return 1; } > > Under 2.2.8-stable gcc 2.7.2.1 and 2.8.1(from ports) this code compilde > Ok. And when I run it, It should return 0. Tested - Ok. > > Under -current - not to be Ok. gcc 2.7.2.1, gcc 2.8.1 and egcs 1.1.1 > compiled Ok, but when I run it code, it return 1. > > -- > Best wishes, Eugeny Kuzakov > Laboratory 321 ( Omsk, Russia ) > kev@lab321.ru > ICQ#: 5885106 > > > -- Best wishes, Eugeny Kuzakov Laboratory 321 ( Omsk, Russia ) kev@lab321.ru ICQ#: 5885106 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.02.9901131959120.1265-100000>