I got the djgpp binary distribution of GPC and made some tests with my pascal aware GDB.
But if I compile a simple program (similar to hello word )
and a start GDB and insert a breakpoint at main (which is what allmost vevery body would do in C, and that works as expected with Free Pascal compiled code)
If I then use "run"
the program stops at the end of the main code, which is rather odd!
If this a known problem and is it or will it be fixed.
The source code used follows I wanted to test the internal form of string to see if I could support it !
program test_gpc(input,output); type string32 = string[32]; var s1, s2 : string32; begin s1:='It '; s2:=s1+'works'; Writeln('It works'); Writeln(s2); end.
Pierre Muller Institut Charles Sadron 6,rue Boussingault F 67083 STRASBOURG CEDEX (France) mailto:muller@ics.u-strasbg.fr Phone : (33)-3-88-41-40-07 Fax : (33)-3-88-41-40-99
Pierre Muller a écrit :
I got the djgpp binary distribution of GPC and made some tests with my pascal aware GDB.
But if I compile a simple program (similar to hello word )
and a start GDB and insert a breakpoint at main (which is what allmost vevery body would do in C, and that works as expected with Free Pascal compiled code)
If I then use "run"
the program stops at the end of the main code, which is rather odd!
If this a known problem and is it or will it be fixed.
I always use GDB within Rhide. I always observed this behaviour. With Step by Step execution (F7), the first step is at end. the next is at the first instruction (s1:='It ';), etc... I have been surprised the first time, but since then I am used to.