[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 74eedc2 030/215: Start js lang. add js backtrace regexp
From: |
Rocky Bernstein |
Subject: |
[elpa] master 74eedc2 030/215: Start js lang. add js backtrace regexp |
Date: |
Sat, 30 Jul 2016 14:48:50 +0000 (UTC) |
branch: master
commit 74eedc2e6d22afaf8c6b3d7e6b195c29c5361787
Author: rocky <address@hidden>
Commit: rocky <address@hidden>
Start js lang. add js backtrace regexp
---
realgud/debugger/nodejs/init.el | 13 +++++++--
realgud/debugger/nodejs/track-mode.el | 1 +
realgud/debugger/trepanjs/backtrack-mode.el | 2 +-
realgud/debugger/trepanjs/init.el | 11 +++-----
realgud/debugger/trepanjs/track-mode.el | 32 +++++++++++++---------
realgud/lang/js.el | 38 +++++++++++++++++++++++++++
6 files changed, 74 insertions(+), 23 deletions(-)
diff --git a/realgud/debugger/nodejs/init.el b/realgud/debugger/nodejs/init.el
index a988c36..979dfc1 100644
--- a/realgud/debugger/nodejs/init.el
+++ b/realgud/debugger/nodejs/init.el
@@ -23,7 +23,7 @@
"../../common/loc"
"../../common/init")
"realgud-")
-(require-relative-list '("../../lang/posix-shell") "realgud-lang-")
+(require-relative-list '("../../lang/js") "realgud-lang-")
(defvar realgud:nodejs-pat-hash)
(declare-function make-realgud-loc-pat (realgud-loc))
@@ -70,7 +70,16 @@ realgud-loc-pat struct")
;; :regexp "^[*] \\([0-9]+\\) "
;; :line-group 1))
-;; Regular expression that describes a debugger "delete" (breakpoint) response.
+;; Regular expression that describes a V8 backtrace line.
+;; For example:
+;; at repl:1:7
+;; at Interface.controlEval
(/src/external-vcs/github/trepanjs/lib/interface.js:352:18)
+;; at REPLServer.b [as eval] (domain.js:183:18)
+(setf (gethash "lang-backtrace" realgud:nodejs-pat-hash)
+ realgud:js-backtrace-loc-pat)
+
+;; Regular expression that describes a debugger "delete" (breakpoint)
+;; response.
;; For example:
;; Removed 1 breakpoint(s).
(setf (gethash "brkpt-del" realgud:nodejs-pat-hash)
diff --git a/realgud/debugger/nodejs/track-mode.el
b/realgud/debugger/nodejs/track-mode.el
index 1ea7795..ff7465c 100644
--- a/realgud/debugger/nodejs/track-mode.el
+++ b/realgud/debugger/nodejs/track-mode.el
@@ -26,6 +26,7 @@
)
"realgud-")
(require-relative-list '("core" "init") "realgud:nodejs-")
+;; (require-relative-list '("../../lang/js") "realgud-lang-")
(declare-function realgud:cmd-remap 'realgud-cmds)
(declare-function realgud:track-set-debugger 'realgud-track-mode)
diff --git a/realgud/debugger/trepanjs/backtrack-mode.el
b/realgud/debugger/trepanjs/backtrack-mode.el
index 32ee7e7..e3b7e6c 100644
--- a/realgud/debugger/trepanjs/backtrack-mode.el
+++ b/realgud/debugger/trepanjs/backtrack-mode.el
@@ -15,7 +15,7 @@
;; You should have received a copy of the GNU General Public License
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
-;;; Mode for parsing various kinds of backtraces found in Ruby
+;;; Mode for parsing various kinds of backtraces found in JavaScript
(eval-when-compile (require 'cl))
(require 'load-relative)
diff --git a/realgud/debugger/trepanjs/init.el
b/realgud/debugger/trepanjs/init.el
index f1eec60..135fd71 100644
--- a/realgud/debugger/trepanjs/init.el
+++ b/realgud/debugger/trepanjs/init.el
@@ -23,7 +23,7 @@
"../../common/loc"
"../../common/init")
"realgud-")
-(require-relative-list '("../../lang/posix-shell") "realgud-lang-")
+(require-relative-list '("../../lang/js") "realgud-lang-")
(defvar realgud:trepanjs-pat-hash (make-hash-table :test 'equal)
"Hash key is the what kind of pattern we want to match:
@@ -78,13 +78,10 @@ realgud-loc-pat struct")
;; at Interface.controlEval
(/src/external-vcs/github/trepanjs/lib/interface.js:352:18)
;; at REPLServer.b [as eval] (domain.js:183:18)
(setf (gethash "lang-backtrace" realgud:trepanjs-pat-hash)
- (make-realgud-loc-pat
- :regexp "^\\(?:[\t ]+at \\)?\\([^:]+\\) (.*:\\([0-9]+\\):\\([0-9]+\\))"
- :file-group 2
- :line-group 3
- :char-offset-group 4))
+ realgud:js-backtrace-loc-pat)
-;; Regular expression that describes a debugger "delete" (breakpoint) response.
+;; Regular expression that describes a debugger "delete" (breakpoint)
+;; response.
;; For example:
;; Deleted breakpoint 1.
(setf (gethash "brkpt-del" realgud:trepanjs-pat-hash)
diff --git a/realgud/debugger/trepanjs/track-mode.el
b/realgud/debugger/trepanjs/track-mode.el
index 4077442..4c02965 100644
--- a/realgud/debugger/trepanjs/track-mode.el
+++ b/realgud/debugger/trepanjs/track-mode.el
@@ -1,5 +1,21 @@
-;;; Copyright (C) 2010, 2012-2015 Rocky Bernstein <address@hidden>
-;;; Ruby "trepanjs" Debugger tracking a comint or eshell buffer.
+;; Copyright (C) 2015 Free Software Foundation, Inc
+
+;; Author: Rocky Bernstein <address@hidden>
+
+;; This program is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; This program is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+;;; "trepanjs" Debugger tracking a comint or eshell buffer.
(eval-when-compile (require 'cl))
(require 'load-relative)
@@ -11,7 +27,7 @@
)
"realgud-")
(require-relative-list '("core" "init") "realgud:trepanjs-")
-(require-relative-list '("../../lang/ruby") "realgud-lang-")
+;; (require-relative-list '("../../lang/js") "realgud-lang-")
(declare-function realgud-track-mode 'realgud-track-mode)
(declare-function realgud-track-mode-hook 'realgud-track-mode)
@@ -28,22 +44,12 @@
(declare-function realgud:ruby-populate-command-keys 'realgud-lang-ruby)
-(defun realgud:trepanjs-goto-control-frame-line (pt)
- "Display the location mentioned by a control-frame line
-described by PT."
- (interactive "d")
- (realgud-goto-line-for-pt pt "control-frame"))
-
(defun realgud:trepanjs-goto-syntax-error-line (pt)
"Display the location mentioned in a Syntax error line
described by PT."
(interactive "d")
(realgud-goto-line-for-pt pt "syntax-error"))
-(realgud:ruby-populate-command-keys trepanjs-track-mode-map)
-
-(define-key trepanjs-track-mode-map
- (kbd "C-c !c") 'realgud:trepanjs-goto-control-frame-line)
(define-key trepanjs-track-mode-map
(kbd "C-c !s") 'realgud:trepanjs-goto-syntax-error-line)
diff --git a/realgud/lang/js.el b/realgud/lang/js.el
new file mode 100644
index 0000000..bb5ab38
--- /dev/null
+++ b/realgud/lang/js.el
@@ -0,0 +1,38 @@
+;; Copyright (C) 2015 Free Software Foundation, Inc
+
+;; Author: Rocky Bernstein <address@hidden>
+
+;; This program is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+
+;; This program is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+(eval-when-compile (require 'cl))
+
+(require 'load-relative)
+(require-relative-list '("../common/regexp" "../common/loc" "../common/track")
+ "realgud-")
+
+(declare-function realgud-goto-line-for-pt 'realgud-track)
+
+;; Regular expression that describes a Perl Carp backtrace line.
+;; at /tmp/foo.pl line 7
+;; main::__ANON__('Illegal division by zero at /tmp/foo.pl line 4.\x{a}')
called at /tmp/foo.pl line 4
+;; main::foo(3) called at /tmp/foo.pl line 8
+(defconst realgud:js-backtrace-loc-pat
+ (make-realgud-loc-pat
+ :regexp "^\\(?:[\t ]+at \\)?\\([^:]+\\)
(\\(.*\\):\\([0-9]+\\):\\([0-9]+\\))"
+ :file-group 2
+ :line-group 3
+ :char-offset-group 4)
+ "A realgud-loc-pat struct that describes a V8 backtrace location")
+
+(provide-me "realgud-lang-")
- [elpa] master 1868152 025/215: core.el: remove duplicate command buffer creation, (continued)
- [elpa] master 1868152 025/215: core.el: remove duplicate command buffer creation, Rocky Bernstein, 2016/07/30
- [elpa] master b920afc 043/215: trepanjs: handle eval properly, Rocky Bernstein, 2016/07/30
- [elpa] master ea27a82 026/215: More copyright assignments to FSF, Rocky Bernstein, 2016/07/30
- [elpa] master 3d74bb5 013/215: More FSF copyright assignments., Rocky Bernstein, 2016/07/30
- [elpa] master 0e68d8d 038/215: common/regexp.el: start to DRY regexps, Rocky Bernstein, 2016/07/30
- [elpa] master 03ecacd 049/215: trepanjs msg change: stop in -> call in, Rocky Bernstein, 2016/07/30
- [elpa] master 986585b 035/215: Revert "Squelch one of the many compiler warnings", Rocky Bernstein, 2016/07/30
- [elpa] master 78aba8b 044/215: DRY with respect to realgud:regexp-captured-num, Rocky Bernstein, 2016/07/30
- [elpa] master bfa52c5 046/215: caddr -> cl-caddr. Fill in %s on format., Rocky Bernstein, 2016/07/30
- [elpa] master 0a1dbc4 036/215: Remove node asci schmutz. put in lang/js.el, Rocky Bernstein, 2016/07/30
- [elpa] master 74eedc2 030/215: Start js lang. add js backtrace regexp,
Rocky Bernstein <=
- [elpa] master 6df0f6a 051/215: trepanjs location format has changed, Rocky Bernstein, 2016/07/30
- [elpa] master bbab251 048/215: gdb: DRY captured number uses., Rocky Bernstein, 2016/07/30
- [elpa] master be999ea 054/215: trepanjs backtrace format changes next release, Rocky Bernstein, 2016/07/30
- [elpa] master 5078d4e 056/215: Doc gdb regexp more., Rocky Bernstein, 2016/07/30
- [elpa] master 0664fb9 037/215: trepanjs/init.el: handle newly added fully-qualified paths, Rocky Bernstein, 2016/07/30
- [elpa] master e5d0f95 057/215: Fix typo poined out by dfelch., Rocky Bernstein, 2016/07/30
- [elpa] master 071b66c 052/215: DRY gub init captured numbered re's., Rocky Bernstein, 2016/07/30
- [elpa] master bd45ec9 023/215: backtrace.el: fix some bugs and remove some warnings, Rocky Bernstein, 2016/07/30
- [elpa] master 8e1ef01 047/215: core.el: correct trepanjs options, Rocky Bernstein, 2016/07/30
- [elpa] master 3a84860 040/215: DRY realgud:regexp-capture-num and add more FSF copyrights, Rocky Bernstein, 2016/07/30