<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<div class="moz-cite-prefix">On 15/12/2017 15:46, Donald Ziesig via
Lazarus wrote:<br>
</div>
<blockquote type="cite"
cite="mid:9619dc5f-1737-1a2e-d712-ec44fffe6b73@ziesig.org">
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<p>Hi All,</p>
<p>I have been working on some <b>serious</b> <span
class="moz-smiley-s12"><span>:-$</span></span> software
libraries that declare generic subprograms and classes. <br>
</p>
<p>While debugging these I noticed:<br>
</p>
<ol>
<li>When single-stepping, the line being highlighted in the
editor window is almost always (but not exclusively) one line
<b>after</b> the line which is about to be executed.</li>
</ol>
</blockquote>
This may be an issue in fpc.<br>
<br>
IIRC<br>
{$IFDEF unknownfoo}<br>
'unclosed string<br>
{$ENDIF}<br>
may also lead to wrong line info<br>
<br>
<blockquote type="cite"
cite="mid:9619dc5f-1737-1a2e-d712-ec44fffe6b73@ziesig.org">
<ol>
<li>When the mouse hovers over a variable, the debugger (and
program being debugged) frequently crashes with the error:<br>
"-data-evaluate-expression TCQPiece(ITEM)^" did not return any
result.<br>
This is particularly annoying because it inevitably happens
just as I am getting close to finding a problem and I move the
mouse across the editor window <span class="moz-smiley-s15"><span>:'(</span></span>.<br>
</li>
</ol>
<p>These problems do not occur when debugging non-generic code.</p>
</blockquote>
This is an issue in gdb.<br>
<br>
First make sure to use dward (debug info).<br>
This must be done for ALL packages too (well all packages that have
debug info).<br>
<br>
But even then you will probably get this error.<br>
<br>
You can try (if it currently compiles / its a package, install it)
lazdebuggerfpgdbmi.lpk (must be the one with gdbmi *and* fp)<br>
And then change the debugger in Tools > Options<br>
<br>
I dont know how good it will be.... <br>
<br>
----------<br>
Also switch of the hint in the options, and use the watch window
only. that way you can control which values you look at.<br>
<br>
--------<br>
you may also try an older gdb (pre 7.6). But again not likely to
help too much.<br>
<br>
</body>
</html>