octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #45764] Errors in user scripts started from 'd


From: Lachlan Andrew
Subject: [Octave-bug-tracker] [bug #45764] Errors in user scripts started from 'debug>' show wrong line numbers
Date: Sat, 15 Aug 2015 00:14:50 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.63 Safari/537.36

URL:
  <http://savannah.gnu.org/bugs/?45764>

                 Summary: Errors in user scripts started from 'debug>' show
wrong line numbers
                 Project: GNU Octave
            Submitted by: lachlan
            Submitted on: Sat 15 Aug 2015 12:14:49 AM GMT
                Category: Interpreter
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Incorrect Result
                  Status: None
             Assigned to: None
         Originator Name: Lachlan
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 4.0.0
        Operating System: GNU/Linux

    _______________________________________________________

Details:

When running in debug mode, Octave does not update the current line number,
although it does update the current file.

If line 100 of file1.m  is "keyboard", and the user runs file2.m which causes
an error, it will report the error as "file2.m, line 100".

This was done so that the stack frame in the original file doesn't get the
wrong line number inserted.  (See comment near line 700 in
libinterp/parse-tree/pt-eval.cc)

The attached patch keeps track of when a new stack frame is created to run
user code, and tracks the line numbers in that new frame, even if it is debug
mode.



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Sat 15 Aug 2015 12:14:49 AM GMT  Name: debug.patch  Size: 5kB   By:
lachlan

<http://savannah.gnu.org/bugs/download.php?file_id=34649>

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?45764>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]