On Fri, 7 Jan 2011 12:24:15 +0100, José Mejuto wrote:
Hello Lazarus-List,

Friday, January 7, 2011, 7:54:17 AM, you wrote:

GG> I have looked into it (at the time), and it seems that if you set a GG> breakpoint in the IDE and save the project. Then modify your code so the
GG> line at which the breakpoint was, is not source code any more
(eg: a blank
GG> line or a comment), the app still breaks at a point close to the original GG> breakpoint, but the IDE doesn't show it as a breakpoint (no red dot, and
GG> not breakpoint listing in the breakpoints window).

In my case the reason is that the code where the real breakpoint is
located has been removed by the linker (non called code) so gdb sets
the breakpoint in the next valid source code line, while editor keeps
the original line for the breakpoint position.

Sounds like you had smart linking enabled. As a rule of thumb you should have no optimizations enabled when debugging: optimization level 0 or 1 and most importantly no smart linking.

--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to