egcs bug? (fwd)
Paul Ezust
ezust@zeus.cas.suffolk.edu
Sun Dec 20 10:09:00 GMT 1998
Thanks for the response.
I was confused by the three different compiler behaviors that
I described in my first message:
gcc version egcs-2.90.27 980315 (egcs-1.0.2 release)
gives an "Internal compiler error".
gcc version egcs-2.91.60 19981201 (egcs-1.1.1 release)
compiles it but produces a run-time error (segmentation fault)
Centerline C++ compiler compiles and runs it with no problem.
(Centerline sells a unix IDE called ObjectCenter.)
One colleague seems to think that compiling it so that it produces
a run-time error is the correct way to handle that error.
That makes me a bit queasy.
-----------------------------------------------------------------
On 20 Dec 1998, Alexandre Oliva wrote:
> On Dec 20, 1998, Alexandre Oliva <oliva@dcc.unicamp.br> wrote:
>
> > On Dec 19, 1998, Paul Ezust <ezust@zeus.cas.suffolk.edu> wrote:
>
> >> int main() { char * const b = "abcdef"; b[3] = '3';
>
> > You can't modify a constant string
>
> Just to make sure it's clear, I meant `string literal' here
>
> --
> Alexandre Oliva http://www.dcc.unicamp.br/~oliva aoliva@{acm.org}
> oliva@{dcc.unicamp.br,gnu.org,egcs.cygnus.com,samba.org}
> Universidade Estadual de Campinas, SP, Brasil
---------------------------------------------------------------------
Paul Ezust Phone: (617) 573-8601
Department of Math & CS Fax: (617) 573-8591
Suffolk University *** Beacon Hill *** Boston, MA 02114-4280
More information about the Gcc-bugs
mailing list