Internal error #122.

Jimmy Timofte jimmyt_104@yahoo.com
Wed Sep 27 05:19:00 GMT 2000


I have compiled with g++ v2.96, on an i686 platform,
RedHat 6.2, the following program:

[jimmy@chopin c++]$ cat bug_encounter.cc
/* bug_encounter.cc */
#include <stdio.h>
#include <string>
 
class ClassX
{
    private:
    int _x;
    string _y;
 
    public:
    ClassX(int x, string y);
};
 
ClassX::ClassX(int x, string y)
{
    _x = x;
    _y = y;
 
    char s[28];
    if (x != 0)
    sprintf(s,"%d%s",_x,_y.c_str();
};
 
int main() { return 0; };
   

and got the following messages:

[jimmy@chopin c++]$ g++ bug_encounter.cc
bug_encounter.cc: In method `ClassX::ClassX (int,
basic_string<char,
string_char_traits<char>,
__default_alloc_template<true, 0> >)':
bug_encounter.cc:22: parse error before `;'
bug_encounter.cc:23: Internal error #122.
bug_encounter.cc:23: Internal compiler error in
finish_function, at
../gcc/cp/decl.c:14409
Please submit a full bug report.
See <URL: http://www.gnu.org/software/gcc/bugs.html >
for instructions.


The version of g++:
[jimmy@chopin c++]$ g++ --version
2.96


The program is indeed wrong, a ")" is missing, but i
guess this is still a bug.


__________________________________________________
Do You Yahoo!?
Send instant messages & get email alerts with Yahoo! Messenger.
http://im.yahoo.com/


More information about the Gcc-bugs mailing list