diff options
| author | Eli Zaretskii | 2020-04-04 14:15:41 +0300 |
|---|---|---|
| committer | Eli Zaretskii | 2020-04-04 14:15:41 +0300 |
| commit | f71afd600aef77d3c7248ae0e94b8c55fb2c5eb2 (patch) | |
| tree | 261284b76fd1ea6bcf50a46bb46bde1b2320ce61 | |
| parent | 05d365d3105371ec956f31f109a2de14c5cf67df (diff) | |
| download | emacs-f71afd600aef77d3c7248ae0e94b8c55fb2c5eb2.tar.gz emacs-f71afd600aef77d3c7248ae0e94b8c55fb2c5eb2.zip | |
Support the "explore" command in gdb-mi.el
* lisp/progmodes/gdb-mi.el (gdb-control-commands-regexp): Add
support for "explore", "explore value", and "explore type".
Allow more than one word after control commands.
(gdb-gdb): Decrease gdb-control-level when we get the "(gdb)"
prompt, which signals that "explore" exited. (Bug#40250)
| -rw-r--r-- | lisp/progmodes/gdb-mi.el | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/lisp/progmodes/gdb-mi.el b/lisp/progmodes/gdb-mi.el index 7fb36873918..07506834f18 100644 --- a/lisp/progmodes/gdb-mi.el +++ b/lisp/progmodes/gdb-mi.el | |||
| @@ -1850,7 +1850,8 @@ static char *magick[] = { | |||
| 1850 | "\\|def\\(i\\(ne?\\)?\\)?\\|doc\\(u\\(m\\(e\\(nt?\\)?\\)?\\)?\\)?\\|" | 1850 | "\\|def\\(i\\(ne?\\)?\\)?\\|doc\\(u\\(m\\(e\\(nt?\\)?\\)?\\)?\\)?\\|" |
| 1851 | gdb-python-guile-commands-regexp | 1851 | gdb-python-guile-commands-regexp |
| 1852 | "\\|while-stepping\\|stepp\\(i\\(ng?\\)?\\)?\\|ws\\|actions" | 1852 | "\\|while-stepping\\|stepp\\(i\\(ng?\\)?\\)?\\|ws\\|actions" |
| 1853 | "\\)\\([[:blank:]]+\\([^[:blank:]]*\\)\\)?$") | 1853 | "\\|expl\\(o\\(r\\e?\\)?\\)?" |
| 1854 | "\\)\\([[:blank:]]+\\([^[:blank:]]*\\)\\)*$") | ||
| 1854 | "Regexp matching GDB commands that enter a recursive reading loop. | 1855 | "Regexp matching GDB commands that enter a recursive reading loop. |
| 1855 | As long as GDB is in the recursive reading loop, it does not expect | 1856 | As long as GDB is in the recursive reading loop, it does not expect |
| 1856 | commands to be prefixed by \"-interpreter-exec console\".") | 1857 | commands to be prefixed by \"-interpreter-exec console\".") |
| @@ -2508,7 +2509,13 @@ file names include non-ASCII characters." | |||
| 2508 | 2509 | ||
| 2509 | gdb-filter-output) | 2510 | gdb-filter-output) |
| 2510 | 2511 | ||
| 2511 | (defun gdb-gdb (_output-field)) | 2512 | (defun gdb-gdb (_output-field) |
| 2513 | ;; This is needed because the "explore" command is not ended by the | ||
| 2514 | ;; likes of "end" or "quit", but instead by a RET at the approriate | ||
| 2515 | ;; place, and we know we have exited "explore" when we get the | ||
| 2516 | ;; "(gdb)" prompt. | ||
| 2517 | (and (> gdb-control-level 0) | ||
| 2518 | (setq gdb-control-level (1- gdb-control-level)))) | ||
| 2512 | 2519 | ||
| 2513 | (defun gdb-shell (output-field) | 2520 | (defun gdb-shell (output-field) |
| 2514 | (setq gdb-filter-output | 2521 | (setq gdb-filter-output |