This is the mail archive of the gcc-prs@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]
Other format: [Raw text]

c++/8762: Internal compiler error.


>Number:         8762
>Category:       c++
>Synopsis:       Internal compiler error.
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          rejects-legal
>Submitter-Id:   net
>Arrival-Date:   Fri Nov 29 17:06:01 PST 2002
>Closed-Date:
>Last-Modified:
>Originator:     bothie@t-online.de
>Release:        gcc version 2.95.3 20010315 (SuSE)
>Organization:
>Environment:
(i386 architecture:) AMD Athlon XP 1700+ (1.466Mhz) / 512MB ram
Linux kernel 2.4.10 (SuSE (de) Linux 7.3 Distribution)
(Note: My kernel is a bit patched, but that should not affect the compiler - it still does a very good job for me without errors all the other time - wanted only to tell ...)
>Description:
/*
$ g++ -v
Reading specs from /usr/lib/gcc-lib/i486-suse-linux/2.95.3/specs
gcc version 2.95.3 20010315 (SuSE)
$ g++ gcc-bug.cc -o gcc-bug
gcc-bug.cc: In function `int any_function()':
gcc-bug.cc:$LINE(buggy=malloc()): Internal compiler error.
gcc-bug.cc:$LINE(buggy=malloc()): Please submit a full bug report.
gcc-bug.cc:$LINE(buggy=malloc()): See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.
$ g++ gcc-bug.cc -o gcc-bug.o -mno-built-in
cc1plus: Invalid option `no-built-in'
gcc-bug.cc: In function `int any_function()':
gcc-bug.cc:$LINE(buggy=malloc()): confused by earlier errors, bailing out

-> The latter call (with argument -mno-built-in) was the try to enter
   '-fno-builtin' - in the hope the problem was the builtin version of malloc()
   but that (-fno-builtin) didn't work (same result as the *first* try).

??? Why cased the argument -mno-built-in, which was not supported (and thusly
    hopefully ignored) the compiler to act in another way as without?

My System:	(i386 architecture) AMD Athlon XP 1700+ (1.466Mhz) / 512MB ram
		Linux kernel 2.4.10 (SuSE (de) Linux 7.3 Distribution)
		(Note:	My kernel is a bit patched, but that should not
			affect the compiler - it still does a very good
			job for me without errors all the other time)
*/
class any_class {
public:
	friend any_class any_friend();
	friend any_class malloc();
};

int any_function() {
	any_class clean,buggy;
	
	clean=any_friend(); /* Works well */
	buggy=malloc();     /* Causes the compiler to fail! */
/* Whatever comes here seems to doesn't affect anything */

>How-To-Repeat:

>Fix:
Please drop me a mail, as soon as you found and corrected the bug (I think it will be added to the official distribution then) so I can download the newest version of gcc (without this bug). I *really* need the friend called malloc!
>Release-Note:
>Audit-Trail:
>Unformatted:


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