"Mike Wahler" <> wrote in message
news:bef4t3$rr3$...
> Peter Gregory <> wrote in message
> news:beerpd$v3k$...
> > Having just upgraded to Mandrake9.1 (hence G++3.2.2) some yacc
> > parsing code that used to work now doesn't. I didn't write the
> > parser and it isn't my code to just put on the web so I can't
> > list it, sorry. I was really just wondering if this is a common
> > problem that has an obvious solution that I'm not seeing.
To the OP:
1) Use the old compiler instead of g++ 3.2.2 (the easy option).
2) Run it through the debugger (probably your best bet).
3) Rewrite the parser from scratch (sounds like fun).
> Yes, "it worked before, but now it doesn't" is indeed
> a very common scenario in software development.
As is, incidentally, "it didn't work before, and it still doesn't". In fact,
that's even more common, if anything...

If we were going to make a
comprehensive list:
(in order of ascending rarity)
1) "it didn't work before, and it still doesn't" (the so-called "oh dear,
rewrite time..." scenario)
2) "it worked before, but now it doesn't" (the "one of the compilers is
messed up, but which?" scenario)
3) "it worked before, and it still does" (the "this code must be trivial"
scenario)
4) "it didn't work before, but now it does" (the "4am debugging session paid
off" scenario (very rare))
In general, the chances of having serious problems when something
inadvertently breaks can be minimised by writing good test code - then when
things do go wrong, it's easier to find out why. Of course, the more
complicated the code, the less this seems to help... Writing good test code
for a parser would probably not be particularly easy to do.
Cheers,
Stuart.
> Did you have a particular question about the C++ language?
>
> http://www.slack.net/~shiva/welcome.txt
>
> -Mike