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]

c++/2418: Internal compiler error reported when unbalanced parentheses are encountered.



>Number:         2418
>Category:       c++
>Synopsis:       Internal compiler error reported when unbalanced parentheses are encountered.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Mar 28 11:56:00 PST 2001
>Closed-Date:
>Last-Modified:
>Originator:     blackw@sfu.ca
>Release:        2.96 20000731 (Red Hat Linux 7.0)
>Organization:
>Environment:
Red Hat Linux 7.0 on Dell Inspiron 8000
Pentium III 700, 192 MB RAM
>Description:
The unbalanced parenthese in the code:

	if ((i == 1) printf ("Hello, World\n");

causes the following compiler error:

	Internal error #122
	Internal compiler error in finish_function, at
	 ..gcc/cp/decl.c14422
	Pleas submit a full bug report
	See <URL:http://www.gnu.org/... (yada, yada, yada)

C compiler correctly identifies the error

	In function '(function name)':
	parse error before 'printf'
>How-To-Repeat:

>Fix:
Obviously, the syntax error can be fixed by the coder.
(Duh! Hense my 'non-critical', 'low priority' bug report.)  
However, since I don't know if this is a side-effect of
a larger defect and considering the compiler asked me to
submit a bug report ... well ... there ya have it.


(Hey, BTW, what's this "Submitter-ID" stuff on the gnatsweb
page, and why does the option 'unknown' appear in the list
if the cgi will not accept it?)
>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]