[Lazarus] lazarus debug with gdb [Re: [fpc-devel] bounty: FPC based debugger]

Martin lazarus at mfriebe.de
Wed Sep 14 21:06:03 CEST 2011

On 13/09/2011 13:12, Joost van der Sluis wrote:
> On Mon, 2011-09-12 at 23:18 +0100, Martin wrote:
>> - dyn array, element access in deeply nested pascal expression (simple
>> cases are normally handled)
> Same as above: works, but maybe not in gdb 7.3 yet.

See attached excel, with
- various fpc,
- stabs or any dwarf
- various gdb

it needs  dynarray^[index]

EXCEPT: dwarf3 + gdb7.3.2
- an anonymously declared dyn-array    (var VarDynIntArrayA: Array of 
     -data-evaluate-expression VarDynIntArrayA[1]
    returns a SINGLE value: ^done,value="22476996"

- a named type dyn array    (type TDynIntArray = Array of Integer;)
     -data-evaluate-expression VarDynIntArray[1]
    returns a SINGLE value: ^done,value="9"

both values make no sense at all => they are not in the list

>> - dyn array: not possible to see the entire list.
> Eh? this one is new for me? What do you mean?

see attached, while a normal array return a list of values (except gdb 
7.0): ^done,value="{10, 12, 14, 16, 18}"
a dyn array returns a pointer, or empty list:   ^done,value="0x775d0"   

-------------- next part --------------
A non-text attachment was scrubbed...
Name: gdb_dyn_array_eval.rar
Type: application/octet-stream
Size: 5502 bytes
Desc: not available
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20110914/c8bf58bd/attachment-0003.obj>

More information about the Lazarus mailing list