This is the mail archive of the gcc@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]

egcs-2.91.55 19980824 error on const references


configure --enable-shared --enable-threads

on both

Linux calumny 2.0.35 #1 Tue Jul 21 15:44:54 EDT 1998 i686 unknown
SunOS yanx 5.5.1 Generic_103640-18 sun4u sparc SUNW,Ultra-2

The following test program fails. It also fails in all earlier versions
of gcc. Would someone please add it to the test suite?

I don't mean to be obnoxious, but I'm going to keep on reporting this
until someone out there fixes it, or adds a test case for it, or at
least acknowledges its existence.

extern "C" int printf(const char *, ...);
int main(int, char **)
{
	volatile const int c = 42;
	volatile int *p;
	volatile const int *&r = p;
	r = &c;
	*p = 0;
	if (c != 42)
		printf("FAILED!\n");
}


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