[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #56860] Debugger can not enter functions decla
[Octave-bug-tracker] [bug #56860] Debugger can not enter functions declared in scripts
Thu, 5 Sep 2019 12:33:53 -0400 (EDT)
Mozilla/5.0 (Windows NT 10.0; WOW64; Trident/7.0; rv:11.0) like Gecko
Update of bug #56860 (project octave):
Category: None => Interpreter
Priority: 5 - Normal => 3 - Low
Status: None => Confirmed
Release: 5.1.0 => dev
Summary: Debugger can not enter functions in scripts =>
Debugger can not enter functions declared in scripts
Follow-up Comment #1:
Confirmed. I think there might be another bug report about this.
The way Octave parses scripts causes any embedded functions to be treated as
command-line functions. This is consistent with the notion that scripts are,
in effect, a laundry list of commands that are each executed exactly as if you
had typed them in to the interpreter.
This analogy appears to break down for the case of the debugger because the
file name attribute, which should be blank for a command-line function since
there is no file, appears to be NULL.
I can actually prove this by typing in the commands directly in to the
interpreter. See the transcript below.
octave:3> function [sum]=add(a,b)
octave:8> dbstop add
ans = 2
octave:9> result2 = add (c,d);
stopped in add at line 2 
stopped in add at line 3 
When I am stopped in the debugger the filename (the value between '[' and ']')
is blank, but apparently not NULL.
This issue is pretty obscure so I can't say when any fix might be developed.
I would simply work around it for now.
Reply to this item at:
Message sent via Savannah