Previous mail
Next mail
Unformatted/full headers
Overview 10 days
Subject
Date
Thread
Author
From: Frank Heckenbach
Subject: Warum geht es nicht mit einer
Date: 6 Mar 2007, 15:54:42
In the German list, Roland Goretzki found a GPC bug (roland2). I've
made a fix for older GPC versions (such as 20040516 he's using),
which is attached.
However, in Waldek's newer GPC versions, the respective code is
"#if 0"d, with the comment: "/* save_expr would cause problems */".
Unfortunately this comment is not very informative to me. I've built
gpc-20060325 with the code back in ("#if 1") on i586-pc-linux-gnu
(Debian 3.1) with gcc-3.4.4, and all tests passed (except roland2,
of course). So I suppose the problems only affect gcc-4.x or other
platforms, is this right?
Then I've applied my patch and all test passed, including roland2.
Anyway, the point is that in the original code, save_expr is only
applied to the string length (which is used twice). However, the
whole string expression may contain side-effects (as in
roland2.pas), and is accessed for the length (once using save_expr,
twice otherwise) and for the chars. So we need to save this. This is
what my patch does, removing the (now useless) save_expr for the
length.
Waldek's code still saves the length, in different way, so the
problem still exists. Perhaps save_expr_string works with
gcc-4/other platforms, so we don't need the new code. If not, can
you change your code to save the whole string, or change
save_expr_string if necessary (as you probably know what you'll have
to test then; I don't).
Frank
Previous mail
Next mail
Unformatted/full headers
Overview 10 days
Subject
Date
Thread
Author
Note: This page contains information that does not originate from the owner of this web site, but from the authors of the mails archived. The owner of this web site is not responsible for the content of such information. Any use of that infomation requires the consent of the respective author.
Where WWW addresses (URLs) in the mails archived are marked as hyperlinks, this is only for the comfort of the reader. The content of the web pages linked to like this does not necessarily reflect the opinion of the owner of this web site or of the authors of the mails archived. The owner of this web site is not responsible for the content of such web pages. Those pages are explicitly not to be considered as part of the content of this page, but merely as references.
This page was created by Crystal 0.999 (Linux 2.4.27/i686).