bugGNU Octave - Bugs: bug #41556, Unable to set multiple breakpoints...

 
 

bug #41556: Unable to set multiple breakpoints with dbstop

Submitted by:  Jérôme <jeromegnu>
Submitted on:  Tue Feb 11 22:25:59 2014  
 
Category: Octave FunctionSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Matlab Compatibility
Status: FixedAssigned to: None
Originator Name: Open/Closed: Closed
Release: devOperating System: Any

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Fri Jan 29 20:14:04 2016, comment #4:

Hi. Sorry, I don't use Octave/Matlab anymore.

Basically, if it allows this to work:

s=dbstatus;
save('breakpoints.mat', 's');
clear all
close all
clc
load('breakpoints.mat', 's');
dbstop(s);

then this bug report can be closed.

Jérôme <jeromegnu>
Sat Dec 12 09:08:07 2015, comment #3:

Input as a struct is supported by the patch at
https://savannah.gnu.org/patch/?8784. Jérôme, could you please have a got of that patch and give me some feedback? Thanks!

Lachlan Andrew <lachlan>
Project Member
Wed Feb 12 14:21:19 2014, comment #2:

Thank you for the workaround. I knew I could do that.

In fact, it is supported in Matlab :

http://www.mathworks.fr/fr/help/matlab/ref/dbstop.html#inputarg_s

Jérôme <jeromegnu>
Wed Feb 12 14:05:55 2014, comment #1:

in help dbstop there is no mention of dbstop accepting input of type struct; therefore, you'll have do something like:

for i=1:numel(s), dbstop(s(i).name, s(i).line); end

you could fill in a feature request for support for struct input in dbstop, but since it's also unsupported in matlab, it'd introduce an incompatibility.

Felipe G. Nievinski <fgnievinski>
Tue Feb 11 22:25:59 2014, original submission:

My objective is to save breakpoints while clearing variables :

-------------------

s=dbstatus;
save('breakpoints.mat', 's');
clear all
close all
clc
load('breakpoints.mat', 's');
dbstop(s);

-------------------

But dbstop does not accept structures :

-------------------

dbstop (s)
error: dbstop: struct input not implemented

-------------------

This output is from dev branch and comes from here :
https://savannah.gnu.org/bugs/?41338

On 3.8, I get this:

-------------------

>> dbstatus

breakpoint in file1 at line 1.
breakpoint in file2 at line 1.

>> s=dbstatus

s =

2x1 struct array containing the fields:

name
file
line

>>
>>
>> dbstop(s)

dbstop: accepting a struct
error: add_breakpoint: unable to find the requested function

>> s(1)

ans =

scalar structure containing the fields:

name = file1
file = /home/jerome/projets/octave/file1.m
line = 1

>> s(2)

ans =

scalar structure containing the fields:

name = file2
file = /home/jerome/projets/octave/file2.m
line = 1

>> dbstop(s)

dbstop: accepting a struct
error: add_breakpoint: unable to find the requested function

>> dbstop(s(1).name, s(1).line)

ans = 1

>> dbstop(s(2).name, s(2).line)

ans = 1

>> dbstop(s)

dbstop: accepting a struct
error: add_breakpoint: unable to find the requested function

-------------------

Jérôme <jeromegnu>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by lachlan (Posted a comment)
  • -unavailable- added by rik5 (Updated the item)
  • -unavailable- added by fgnievinski (Posted a comment)
  • -unavailable- added by jeromegnu (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue Feb 16 02:05:08 2016rik5Open/ClosedOpen=>Closed
    Mon Feb 8 05:39:50 2016lachlanStatusConfirmed=>Fixed
      Operating SystemGNU/Linux=>Any
    Mon Dec 29 04:49:26 2014rik5StatusNone=>Confirmed

    Back to the top


    Powered by Savane 3.1-cleanup