[fpc-pascal]Re: New GDB version 5.1 available

Pierre Muller pierre at freepascal.org
Mon Dec 17 09:30:31 CET 2001

At 21:29 15/12/2001 , Maurice Lombardi a écrit:
>Andris Pavenis wrote:
>>On Saturday 15 December 2001 12:47, Maurice Lombardi wrote:
>>>Pierre Muller wrote:
>>>>  This is just to inform people that
>>>>GDB 5.1 was released.
>>>>* Support for debugging Pascal programs.
>>>>    - unlike Pascal, GDB is case-sensitive for symbol names.
>>>Do you plan to do something for that ?
>>>I use gdb nearly only through Rhide.
>>>We can ask to Robert to capitalize identifiers in the gpc or fpc
>>>style (somebody already asked him). It will be necessary to
>>>take somehow into account the nature (C or Pascal) of the module in which
>>>these identifiers are defined (gpc can call C routines).
>>>It is useless for him to do that in the rhide interface if GDB already
>>I haven't looked in details what Robert has done, but as far as I saw he
>>has included a better support of GDB-5.1 in current CVS version of RHIDE
>>in comparission with one I used in Anyway my build of rhide-
>>is built using GDB-5.1. I don't know about support of debugging Pascal
>>programs. It's possible one still has to enter identifiers in upercase. I haven't tested that
>I have downloaded and built GDB-5.1 (GNU version) for djgpp to compare.
>There is no capitalization in GDB-5.1
>in (and was the same in 1.4.9), there seems to be some experimentation.
>No capitalization at all for Ctrl-F4 (Evaluate/Modify)

Capitalization should only be a problem for records,
for normal variables, the search goes the following way:
if I type 
(gdb) print TestVariable
inside gdb when current language is pascal.
  1) Search for a global (or static) symbol  'TestVariable' as typed.
  2) Search for the all capitalized version 'TESTVARIABLE'.
  3) Search for the GPC version 'Testvariable'.
And finally, restore the as typed version if none of the three is found.

   The problem is that for fields of a record, the type of the record just parsed is
not remembered, so that the field isn't found...
But for normal variables all should work fine.

>   As expected Change do not work: the GDB windows shows the command
>   set variable N=3
>   (instead of set variable:=3 for pascal).
>FPC capitalisation for Ctrl-F7 (Watch), i.e. ALL UPPERCASE
>   for gpc in should be Only First Letter Uppercase.
>   It is possible to select one or other depending whether
>  Option/Environment/preference/Use FPC Compiler 
>  is checked or not.

That should be possible easily indeed...
The best solution would be to use the language dependent operators that are part
of the language definition.

   The biggest problem is that I didn't compile RHIDE 
for more than two years, so it might take some time until I can get 
back into it.

>Otherwise the syntax seems to be much more natural for a Pascal programmer.
>So I am very interested to see the progresses in this work.

    Which sources should I get? Apparently there are now two versions on the net...

More information about the fpc-pascal mailing list