Alfredo Cesar Fontana wrote:
Hello:
In this example:
PROGRAM STR; {$IFDEF BAD} TYPE P=PROCEDURE(S:STRING); {$ENDIF} VAR S:STRING; BEGIN S:='123'; DELETE(S,1,1); WRITELN(S) END.
with GPC v 19990118 (DJGPP and Linux) and GPC v 19990609
when I "gpc -o str str.pas" I get: "23", the delete procedure works fine. But if I "gpc -o str str.pas -DBAD" then I get: "123". I lost my delete procedure :'-(
Thanks for the report, I'm adding it to the To-Do list and testsuite (fontana1.pas).
I've traced the problem to parse.y:2196, but I can't fix it because there are strange things going on in that area which I don't understand.
Frank