[PATCH v3 0/2] MI: Add new command -complete

Jan Vrany
2019-03-04T14:52:15Z

This is a rework of v2 patch based on Pedro's comments.

Differences v2 -> v3:

* to support wildmatching, the command output had to change to
provide both, "completion" (what a frontend should complete)
and "matches" (a list of possible completions)
* and some formatting issues.

Differences v1 -> v2:

* extracted common completion logic to a new helper function
* implemented MI command using a new mi-specific function rather
than using CLI implementation.

Jan Vrany (2):
MI: extract command completion logic from complete_command()
MI: Add new command -complete

gdb/ChangeLog | 14 ++++++
gdb/NEWS | 7 +++
gdb/cli/cli-cmds.c | 30 +----------
gdb/completer.c | 36 +++++++++++++
gdb/completer.h | 7 +++
gdb/doc/ChangeLog | 5 ++
gdb/doc/gdb.texinfo | 57 +++++++++++++++++++++
gdb/mi/mi-cmds.c | 2 +
gdb/mi/mi-cmds.h | 1 +
gdb/mi/mi-main.c | 49 ++++++++++++++++++
gdb/testsuite/ChangeLog | 5 ++
gdb/testsuite/gdb.mi/mi-complete.cc | 21 ++++++++
gdb/testsuite/gdb.mi/mi-complete.exp | 75 ++++++++++++++++++++++++++++
13 files changed, 280 insertions(+), 29 deletions(-)
create mode 100644 gdb/testsuite/gdb.mi/mi-complete.cc
create mode 100644 gdb/testsuite/gdb.mi/mi-complete.exp

--
2.20.1