Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2010-06

Debugger output style

4 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Mark Morgan Lloyd

Is there an easy way of telling the debugger to display a variable as hex for ease of bit-twiddling? I can see that watchpoints have an associated style but it's greyed out here.

Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues]

Reply by email

Graeme Geldenhuys
to Mark Morgan Lloyd
Mark Morgan Lloyd wrote
Is there an easy way of telling the debugger to display a variable as hex for ease of bit-twiddling? I can see that watchpoints have an associated style but it's greyed out here.

I asked that same question a few months back. All the greyed out options are not implemented yet. Patches are welcome. ;-)

Regards, - Graeme - _______________________________________________ fpGUI - a cross-platform Free Pascal GUI toolkit http://opensoft.homeip.net/fpgui/

Reply by email

Martin
to Mark Morgan Lloyd: Is there an easy way of telling the debugger to display a variable as hex for ease of…
Mark Morgan Lloyd wrote
Is there an easy way of telling the debugger to display a variable as hex for ease of bit-twiddling? I can see that watchpoints have an associated style but it's greyed out here.

There is a way, but more like a workaround. Doesn't work for locals, put works in Watches window:

Pointer(MyVar)

Btw, if you need spaces in an expression
MyVar and 255
you actually need to quote it by hand:
"MyVar and 255"

Include the quotes in the watches win, and it will work.

Reply by email

Mark Morgan Lloyd
to Martin
Martin wrote 17 lines
On 24/06/2010 13:25, Mark Morgan Lloyd wrote: > Is there an easy way of telling the debugger to display a variable as > hex for ease of bit-twiddling? I can see that watchpoints have an > associated style but it's greyed out here. > There is a way, but more like a workaround. Doesn't work for locals, put works in Watches window: Pointer(MyVar) Btw, if you need spaces in an expression MyVar and 255 you actually need to quote it by hand: "MyVar and 255" Include the quotes in the watches win, and it will work.

Thanks both. I ended up hacking it with a temporary conversion in the code which allowed me to see what I'd done wrong :-)

Getting the missing watchpoint style coded sounds like a tricky job since it would presumably need additions to whatever makes the internal structure persistent, as well as the UI for setting it up and handling the display.

Mark Morgan Lloyd markMLl .AT. telemetry.co .DOT. uk [Opinions above are the author's, not those of his employers or colleagues]

Reply by email