Recent

Author Topic: [INFORMATION] IDE stops on line where is no breakpoint. Case 2  (Read 1893 times)

yurkad

  • Full Member
  • ***
  • Posts: 173
  • development
Lazarus Version 1.6

It is only Information.

I saw similar topic
http://forum.lazarus.freepascal.org/index.php/topic,14860.msg79148.html#msg79148

In  window Menu > View > Debug windows > Breakpoints was only one line:
SomeFolder\SomeFile.pas          Line 90

After this I opened file MyProject.lps with WordPad Editor.

There was two significant groups of lines:

<Item1>
  <Kind Value="bpkSource"/>
  <WatchScope Value="wpsLocal"/>
  <WatchKind Value="wpkWrite"/>
  <Source Value="SomeFolder\SomeFile.pas"/>
  <Line Value="90"/>
</Item1> 


and

<Position20>
  <Filename Value="SomeFile.pas"/>
  <Caret Line="91" TopLine="77"/>
</Position20>


Well.

The file SomeFolder\SomeFile.pas  already does not exists in disk during several days.

The IDE stops in line 91 of  file SomeFile.pas.
Line 90 of  file SomeFile.pas is Empty.

The problem was solved.

Just in case:
File MyProject.lps has two references to file SomeFolder\SomeFile.pas.
Second is:
<Unit15>
  <Filename Value="SomeFolder\SomeFile.pas"/>

...
</Unit15>


Thanks.


Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 9908
  • Debugger - SynEdit - and more
    • wiki
Re: [INFORMATION] IDE stops on line where is no breakpoint. Case 2
« Reply #1 on: April 28, 2016, 02:43:33 pm »
There are 2 issues here:

1) the lps contains settings for a none existing file. That should probably be fixed. Though it may depend on how the file was deleted, and if the IDE was aware of it been deleted.

2) The breakpoint is actually set, in a "different" file. "different" here meaning a file in a different folder, but with the same name.
This can currently not be fixed. If the IDE tries to set a breakpoint using full path info, then in certain cases gdb will not set it, even though the file exists. Therefore breakpoints are handed to gdb by filename only.
So if the file exists by name, even in a different path, then the breakpoint will be set.

yurkad

  • Full Member
  • ***
  • Posts: 173
  • development
Re: [INFORMATION] IDE stops on line where is no breakpoint. Case 2
« Reply #2 on: April 28, 2016, 10:22:38 pm »
Thanks for good explanation.

 

TinyPortal © 2005-2018